Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 6 Aug 1997 23:30:01 -0700 (PDT)
From:      j@uriah.heep.sax.de (J Wunsch)
To:        freebsd-bugs
Subject:   Re: bin/4238: chpass only occasionally works in conjunction with ed
Message-ID:  <199708070630.XAA21958@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/4238; it has been noted by GNATS.

From: j@uriah.heep.sax.de (J Wunsch)
To: schweikh@noc.dfn.de
Cc: freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: bin/4238: chpass only occasionally works in conjunction with ed
Date: Thu, 7 Aug 1997 08:18:36 +0200

 As schweikh@noc.dfn.de wrote:
 
 > When I try to change the home directory of user 'toor' from
 > /root to whatever using the editor ed (see below) and chpass
 > then chpass only accepts the changes occasionally.
 
 UTSL.  You could have easily found the reason yourself:
 
 		if (begin.st_mtime == end.st_mtime) {
 			warnx("no changes made");
 			pw_error(NULL, 0, 0);
 		}
 
 That is, the editing process needs to last for at least one second
 right now, in order for chpass(1) to notice the modification on the
 file since it's only done using the file modification timestamp.
 
 Fix: include st_mtimensec into the consideration.
 
 -- 
 cheers, J"org
 
 joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE
 Never trust an operating system you don't have sources for. ;-)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199708070630.XAA21958>