* select.cc (allocfd_set): Zero allocated fd_set.

(cygwin_select): Move fd_set copying logic from ::wait to here.  Use common
return through sell.poll.
(select_stuff::wait): Just return success or failure and let caller fill in
fd_set.
* pinfo.h (pinfo): Eliminate self-referential pointer to sidbuf since pinfo
structure exists at random locations now.
* fork.cc (fork): Use 'use_psid' element to control when the psid is relevant.
* shared.cc (sec_user): Ditto.
* spawn.cc (spawn_guts): Ditto.
* uinfo.cc (internal_getlogin): Ditto.
* syscall.cc (seteuid): Ditto.  Set use_psid element.
This commit is contained in:
Christopher Faylor
2000-08-09 02:33:47 +00:00
parent c51a2a8ba4
commit 0072fdab86
8 changed files with 69 additions and 68 deletions

View File

@ -1865,7 +1865,6 @@ seteuid (uid_t uid)
}
struct _pinfo pi;
pi.psid = (PSID) pi.sidbuf;
/* pi.token is used in internal_getlogin() to determine if
impersonation is active. If so, the token is used for
retrieving user's SID. */
@ -1884,7 +1883,8 @@ seteuid (uid_t uid)
strcpy (myself->username, pi.username);
strcpy (myself->logsrv, pi.logsrv);
strcpy (myself->domain, pi.domain);
memcpy (myself->sidbuf, pi.sidbuf, MAX_SID_LEN);
memcpy (myself->psid, pi.psid, MAX_SID_LEN);
myself->use_psid = 1;
}
}
else