Subject: bin/5107: Yes, I know 'Vi saved the file,' you've told me 15 times.
To: None <gnats-bugs@gnats.netbsd.org>
From: None <cgd@NetBSD.ORG>
List: netbsd-bugs
Date: 03/03/1998 09:34:03
>Number: 5107
>Category: bin
>Synopsis: vi recover file notificaton just keeps on notifying.
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people (Utility Bug People)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Tue Mar 3 09:35:00 1998
>Last-Modified:
>Originator: Chris G. Demetriou
>Organization:
Kernel Hackers 'r' Us
>Release: NetBSD-current as of March 2, 1998
>Environment:
System: NetBSD brick.demetriou.com 1.3D NetBSD 1.3D (BRICK) #36: Wed Feb 18 21:00:25 PST 1998 cgd@brick.demetriou.com:/usr/src/sys/arch/i386/compile/BRICK i386
>Description:
vi recover file notification doesn't work so well. Actually,
i suppose to works too well; instead of getting one notification
message per recovered file, you get one _per reboot_. This can
be... annoying for people doing development who don't often clear
out the recover files.
>How-To-Repeat:
vi a file. make some modifications but don't save them.
'shutdown -r now'. Note that when the editor is killed, you
get a recovery file in /var/tmp/vi.recover.
Reboot. Note that you get a recovery message. Delete it.
Reboot. Note that you get a recovery message. Delete it.
Reboot. Note that you get a recovery message. Delete it.
(etc.) (If you just HUP the editor manually, you'll get one
recovery when you do that, and will get more when the machine
reboots.)
>Fix:
Instead of using the short chunk of /etc/rc which is currently
handling vi recovery files, use something more like the script
found in /usr/src/usr.bin/vi/recover. (It'd probably be best
to install the script, then call it from /etc/rc, rather than
stuffing it directly in /etc/rc. "Oh for init.d/rc.d...")
>Audit-Trail:
>Unformatted: