summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <joerg@mysql.com>2004-09-30 19:05:33 +0200
committerunknown <joerg@mysql.com>2004-09-30 19:05:33 +0200
commit6882e87f15b6dfebdf8482f421a0d3e53ca1d11f (patch)
tree8f56a37eefd55865175bc9ae3bd68ffc909fc598
parenta8cbb00d5c61db88c06ce4a58004a034bc70a45f (diff)
downloadmariadb-git-6882e87f15b6dfebdf8482f421a0d3e53ca1d11f.tar.gz
Solve compile problem for 4.0.22 on hpita2. (Backport of a 4.1 change)
sql/mysqld.cc: Replace 'sete_id(_)' calls by 'setre_id(-1,_)' calls, as the former have no prototypes on some platforms. (Backport of a 4.1 change)
-rw-r--r--sql/mysqld.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/sql/mysqld.cc b/sql/mysqld.cc
index 834cff0d869..89d71ecbfa2 100644
--- a/sql/mysqld.cc
+++ b/sql/mysqld.cc
@@ -1114,14 +1114,14 @@ static void set_effective_user(struct passwd *user_info)
{
#if !defined(__WIN__) && !defined(OS2) && !defined(__NETWARE__)
DBUG_ASSERT(user_info);
- if (setegid(user_info->pw_gid) == -1)
+ if (setregid((gid_t)-1,user_info->pw_gid) == -1)
{
- sql_perror("setegid");
+ sql_perror("setregid");
unireg_abort(1);
}
- if (seteuid(user_info->pw_uid) == -1)
+ if (setreuid((uid_t)-1,user_info->pw_uid) == -1)
{
- sql_perror("seteuid");
+ sql_perror("setreuid");
unireg_abort(1);
}
#endif
@@ -2510,9 +2510,9 @@ You should consider changing lower_case_table_names to 1 or 2",
#if defined(HAVE_MLOCKALL) && defined(MCL_CURRENT)
if (locked_in_memory && !getuid())
{
- if (seteuid(0) == -1)
+ if (setreuid((uid_t)-1,0) == -1)
{ // this should never happen
- sql_perror("seteuid");
+ sql_perror("setreuid");
unireg_abort(1);
}
if (mlockall(MCL_CURRENT))