Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
57694d52
Commit
57694d52
authored
Aug 30, 2012
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MDEV-395 PR_SET_DUMPABLE set in unreachable code
parent
b45c551e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
sql/mysqld.cc
sql/mysqld.cc
+9
-3
No files found.
sql/mysqld.cc
View file @
57694d52
...
...
@@ -2026,13 +2026,19 @@ static struct passwd *check_user(const char *user)
if
(
!
(
tmp_user_info
=
getpwuid
(
atoi
(
user
))))
goto
err
;
}
return
tmp_user_info
;
/* purecov: end */
err:
sql_print_error
(
"Fatal error: Can't change to run as user '%s' ; Please check that the user exists!
\n
"
,
user
);
unireg_abort
(
1
);
#endif
return
NULL
;
}
static
inline
void
allow_coredumps
()
{
#ifdef PR_SET_DUMPABLE
if
(
test_flags
&
TEST_CORE_ON_SIGNAL
)
{
...
...
@@ -2040,11 +2046,9 @@ err:
(
void
)
prctl
(
PR_SET_DUMPABLE
,
1
);
}
#endif
#endif
return
NULL
;
}
static
void
set_user
(
const
char
*
user
,
struct
passwd
*
user_info_arg
)
{
/* purecov: begin tested */
...
...
@@ -2071,6 +2075,7 @@ static void set_user(const char *user, struct passwd *user_info_arg)
sql_perror
(
"setuid"
);
unireg_abort
(
1
);
}
allow_coredumps
();
#endif
/* purecov: end */
}
...
...
@@ -2090,6 +2095,7 @@ static void set_effective_user(struct passwd *user_info_arg)
sql_perror
(
"setreuid"
);
unireg_abort
(
1
);
}
allow_coredumps
();
#endif
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment