[1942] in Athena Bugs

home help back first fref pref prev next nref lref last post

(VS2) Version 6.1C: toehold

daemon@ATHENA.MIT.EDU (John T Kohl)
Tue Mar 21 12:23:41 1989

Date: Tue, 21 Mar 89 12:22:45 EST
From: John T Kohl <jtkohl@ATHENA.MIT.EDU>
To: bugs@ATHENA.MIT.EDU
System type, version:	(VS2) Version 6.1C
System name:		lycus
What's wrong:
Toehold never closes /etc/utmp.  Examine code in wait_alarm():
    if((file = open(utmpf, O_RDONLY, 0)) >= 0) {
	while(read(file, (char *) &utmp, sizeof(utmp)) > 0) {
	    if(*utmp.ut_name) goto no_deactivate;
	}
	deactivate_workstation();
    }

    /* Here if someone's logged in or we can't open utmp */
  no_deactivate:
    /* If we don't have an X, restart toehold */
    if(!wpid) {
	die(0);
    }

What should have happened:

It should clean up, like all good programs.

home help back first fref pref prev next nref lref last post