aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/syscalls.cc
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2000-07-02 10:17:44 +0000
committerCorinna Vinschen <corinna@vinschen.de>2000-07-02 10:17:44 +0000
commit0c4d2abd9966366b5e215ae64ce3b620efca9335 (patch)
tree62f506a304925c9d2707c73ce5c340daedff8338 /winsup/cygwin/syscalls.cc
parentc570d680fb3ffcfc973d13e56eabd143b0940cb3 (diff)
downloadnewlib-0c4d2abd9966366b5e215ae64ce3b620efca9335.zip
newlib-0c4d2abd9966366b5e215ae64ce3b620efca9335.tar.gz
newlib-0c4d2abd9966366b5e215ae64ce3b620efca9335.tar.bz2
* winsup.h: Define MAX_SID_LEN and new MAX_HOST_NAME.
* fork.cc (fork): Use above defines instead of numerical constants. * shared.cc (sec_user): Ditto. * shared.h (class pinfo): Ditto. * syscall.cc (seteuid): Ditto. * spawn.cc (_spawnve): Ditto. Eliminate conditional. (spawn_guts): Set child->uid = USHRT_MAX when user context will be changed in child process. * uinfo.cc (uinfo_init): Check for myself->uid instead of myself->psid to avoid reloading of /etc/passwd on process startup if ntsec is off. Use above defines instead of numerical constants. * security.cc: Move define for MAX_SID_LEN to winsup.h.
Diffstat (limited to 'winsup/cygwin/syscalls.cc')
-rw-r--r--winsup/cygwin/syscalls.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc
index 592e97c..4a93869 100644
--- a/winsup/cygwin/syscalls.cc
+++ b/winsup/cygwin/syscalls.cc
@@ -1872,7 +1872,7 @@ seteuid (uid_t uid)
}
myself->uid = uid;
strcpy (myself->username, pi.username);
- CopySid (40, myself->psid, pi.psid);
+ CopySid (MAX_SID_LEN, myself->psid, pi.psid);
strcpy (myself->logsrv, pi.logsrv);
strcpy (myself->domain, pi.domain);
}