- (stevesk) bsd-cray.c: more cleanup; ok wendyp@cray.com
This commit is contained in:
parent
72992afb26
commit
4da21abd24
|
@ -4,6 +4,7 @@
|
||||||
- (stevesk) sshpty.c: return 0 on error in cray pty code;
|
- (stevesk) sshpty.c: return 0 on error in cray pty code;
|
||||||
ok wendyp@cray.com
|
ok wendyp@cray.com
|
||||||
- (stevesk) bsd-cray.c: utmp strings are not C strings
|
- (stevesk) bsd-cray.c: utmp strings are not C strings
|
||||||
|
- (stevesk) bsd-cray.c: more cleanup; ok wendyp@cray.com
|
||||||
|
|
||||||
20010812
|
20010812
|
||||||
- (djm) Fix detection of long long int support. Based on patch from
|
- (djm) Fix detection of long long int support. Based on patch from
|
||||||
|
@ -6285,4 +6286,4 @@
|
||||||
- Wrote replacements for strlcpy and mkdtemp
|
- Wrote replacements for strlcpy and mkdtemp
|
||||||
- Released 1.0pre1
|
- Released 1.0pre1
|
||||||
|
|
||||||
$Id: ChangeLog,v 1.1473 2001/08/14 20:54:52 stevesk Exp $
|
$Id: ChangeLog,v 1.1474 2001/08/14 21:02:15 stevesk Exp $
|
||||||
|
|
|
@ -35,9 +35,7 @@ char cray_tmpdir[TPATHSIZ+1]; /* job TMPDIR path */
|
||||||
* Functions.
|
* Functions.
|
||||||
*/
|
*/
|
||||||
void cray_retain_utmp(struct utmp *, int);
|
void cray_retain_utmp(struct utmp *, int);
|
||||||
void cray_create_tmpdir(int, uid_t, gid_t);
|
void cray_delete_tmpdir(char *, int, uid_t);
|
||||||
void cray_delete_tmpdir(char *, int , uid_t);
|
|
||||||
void cray_job_termination_handler (int);
|
|
||||||
void cray_init_job(struct passwd *);
|
void cray_init_job(struct passwd *);
|
||||||
void cray_set_tmpdir(struct utmp *);
|
void cray_set_tmpdir(struct utmp *);
|
||||||
|
|
||||||
|
@ -73,8 +71,8 @@ cray_setup(uid_t uid, char *username)
|
||||||
if (p == NULL)
|
if (p == NULL)
|
||||||
fatal("No UDB entry for %.100s", username);
|
fatal("No UDB entry for %.100s", username);
|
||||||
if (uid != p->ue_uid)
|
if (uid != p->ue_uid)
|
||||||
fatal("UDB etnry %.100s uid(%d) does not match uid %d",
|
fatal("UDB entry %.100s uid(%d) does not match uid %d",
|
||||||
username, p->ue_uid, uid);
|
username, (int) p->ue_uid, (int) uid);
|
||||||
for (j = 0; p->ue_acids[j] != -1 && j < MAXVIDS; j++) {
|
for (j = 0; p->ue_acids[j] != -1 && j < MAXVIDS; j++) {
|
||||||
accts[naccts] = p->ue_acids[j];
|
accts[naccts] = p->ue_acids[j];
|
||||||
naccts++;
|
naccts++;
|
||||||
|
@ -133,13 +131,13 @@ drop_cray_privs()
|
||||||
|
|
||||||
memset(&usrv, 0, sizeof(usrv));
|
memset(&usrv, 0, sizeof(usrv));
|
||||||
if (setusrv(&usrv) < 0)
|
if (setusrv(&usrv) < 0)
|
||||||
fatal("%s(%d): setusrv(): %s\n", __FILE__, __LINE__,
|
fatal("%s(%d): setusrv(): %s", __FILE__, __LINE__,
|
||||||
strerror(errno));
|
strerror(errno));
|
||||||
|
|
||||||
if ((privstate = priv_init_proc()) != NULL) {
|
if ((privstate = priv_init_proc()) != NULL) {
|
||||||
result = priv_set_proc(privstate);
|
result = priv_set_proc(privstate);
|
||||||
if (result != 0 )
|
if (result != 0 )
|
||||||
fatal("%s(%d): priv_set_proc(): %s\n",
|
fatal("%s(%d): priv_set_proc(): %s",
|
||||||
__FILE__, __LINE__, strerror(errno));
|
__FILE__, __LINE__, strerror(errno));
|
||||||
priv_free_proc(privstate);
|
priv_free_proc(privstate);
|
||||||
}
|
}
|
||||||
|
@ -202,7 +200,7 @@ cray_delete_tmpdir(char *login, int jid, uid_t uid)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ((child = fork()) == 0) {
|
if ((child = fork()) == 0) {
|
||||||
execl(CLEANTMPCMD, CLEANTMPCMD, login, jtmp, 0);
|
execl(CLEANTMPCMD, CLEANTMPCMD, login, jtmp, (char *)NULL);
|
||||||
fatal("cray_delete_tmpdir: execl of CLEANTMPCMD failed");
|
fatal("cray_delete_tmpdir: execl of CLEANTMPCMD failed");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue