From joelh@detlev.piqnet.org  Thu Feb 24 15:02:05 2000
Return-Path: <joelh@detlev.piqnet.org>
Received: from heimdall.piqnet.org (adsl-63-197-64-194.dsl.snfc21.pacbell.net [63.197.64.194])
	by hub.freebsd.org (Postfix) with ESMTP id 3423437BC05
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 24 Feb 2000 15:02:04 -0800 (PST)
	(envelope-from joelh@detlev.piqnet.org)
Received: from detlev.piqnet.org (adsl-63-197-64-195.dsl.snfc21.pacbell.net [63.197.64.195])
	by heimdall.piqnet.org (8.9.3/8.9.3) with ESMTP id PAA11175
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 24 Feb 2000 15:06:31 -0800 (PST)
	(envelope-from joelh@detlev.piqnet.org)
Received: (from joelh@localhost)
	by detlev.piqnet.org (8.9.3/8.9.3) id PAA79693;
	Thu, 24 Feb 2000 15:03:44 -0800 (PST)
	(envelope-from joelh)
Message-Id: <200002242303.PAA79693@detlev.piqnet.org>
Date: Thu, 24 Feb 2000 15:03:44 -0800 (PST)
From: Joel Ray Holveck <joelh@piqnet.org>
Sender: joelh@detlev.piqnet.org
Reply-To: joelh@gnu.org
To: freefall-gnats@detlev.piqnet.org
Subject: Exiting from /usr/sbin/login does not restore utmp
X-Send-Pr-Version: 3.2

>Number:         16971
>Category:       bin
>Synopsis:       Exiting from /usr/sbin/login does not restore utmp
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Feb 24 15:10:01 PST 2000
>Closed-Date:    Thu Oct 11 15:13:27 PDT 2001
>Last-Modified:  Thu Oct 11 15:14:12 PDT 2001
>Originator:     Joel Ray Holveck
>Release:        FreeBSD 4.0-CURRENT i386
>Organization:
>Environment:

	Current from 10 Feb

>Description:

	After login exits when invoked from the shell, it does not
restore utmp to indicate the old user.

>How-To-Repeat:

The following has been minorly edited to eliminate motds, etc.
joelh's shell is bash 2.02.  It runs login out of /usr/bin and forks
as if it were running any other program.  The telnet is to force a
clean environment.

detlev$ telnet 127.0.0.1
Trying 127.0.0.1...
Connected to localhost (127.0.0.1).
Escape character is '^]'.

FreeBSD/i386 (detlev.piqnet.org) (ttypb)

login: joelh
s/key 94 de20359
Password: 
Last login: Thu Feb 24 14:31:14 from localhost
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
	The Regents of the University of California.  All rights reserved.

FreeBSD 4.0-CURRENT (DETLEV) #0: Fri Feb 11 01:37:14 PST 2000
detlev$ tty
/dev/ttypb
detlev$ w | grep pb
joelh            pb       localhost         2:34PM     - grep pb
detlev$ login smt
Password:
Last login: Thu Feb 24 14:31:27 on ttypa
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
	The Regents of the University of California.  All rights reserved.

FreeBSD 4.0-CURRENT (DETLEV) #0: Fri Feb 11 01:37:14 PST 2000
bash-2.02$ w | grep pb
smt             pb       -                 2:34PM     - grep pb
bash-2.02$ logout
detlev$ w | grep pb
smt             pb       -                 2:34PM     - grep pb
detlev$ logout

>Fix:


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: johan 
State-Changed-When: Thu Oct 11 15:13:27 PDT 2001 
State-Changed-Why:  
Kind of duplicate of PR 5483. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=16971 
>Unformatted:
