From tolik@www.tomsk.su  Wed Jul  2 01:18:01 1997
Received: from www.tomsk.su (www.tomsk.su [193.124.185.18])
          by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id BAA21167
          for <FreeBSD-gnats-submit@freebsd.org>; Wed, 2 Jul 1997 01:17:38 -0700 (PDT)
Received: (from tolik@localhost)
	by www.tomsk.su (8.8.5/8.8.5) id MAA21297;
	Wed, 2 Jul 1997 12:27:01 +0800 (TSD)
Message-Id: <199707020427.MAA21297@www.tomsk.su>
Date: Wed, 2 Jul 1997 12:27:01 +0800 (TSD)
From: "Anatoly A. Orehovsky" <tolik@www.tomsk.su>
Reply-To: tolik@www.tomsk.su
To: FreeBSD-gnats-submit@freebsd.org
Subject: Problem with edquota -t - tmpfile not removed after exit
X-Send-Pr-Version: 3.2

>Number:         4010
>Category:       bin
>Synopsis:       Problem with edquota -t - tmpfile not removed after exit
>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:   Wed Jul  2 01:20:01 PDT 1997
>Closed-Date:    Tue Aug 19 13:45:57 PDT 1997
>Last-Modified:  Tue Aug 19 13:46:15 PDT 1997
>Originator:     Anatoly A. Orehovsky
>Release:        FreeBSD 2.2.2-RELEASE i386
>Organization:
CISA Ltd.
>Environment:

	

>Description:

edquota -t after exit leaved lost tmpfile into TMPDIR

>How-To-Repeat:

Simple:
edquota -t

>Fix:

Patch:

*** edquota.c.orig	Wed Jul  2 11:59:27 1997
--- edquota.c	Wed Jul  2 12:00:23 1997
*************** main(argc, argv)
*** 161,166 ****
--- 161,168 ----
  		if (editit(tmpfil) && readtimes(protoprivs, tmpfil))
  			putprivs(0, quotatype, protoprivs);
  		freeprivs(protoprivs);
+ 		close(tmpfd);
+ 		unlink(tmpfil);
  		exit(0);
  	}
  	for ( ; argc > 0; argc--, argv++) {

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: jlemon 
State-Changed-When: Tue Aug 19 13:45:57 PDT 1997 
State-Changed-Why:  

Fix applied, thanks! 
>Unformatted:
