🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.emacs.bug
Article #98898

Re: ftp-write-file/problems

#98898
From: Kyle Jones
Date: Tue, 29 Jan 1991 20:36
20 lines
1753 bytes
teape@hslrswi.hasler.ascom.ch (Andrew Kiggins) writes:
 > emacs-18.55/Sun3/80/Openlook/vax/BSD4.2
 > ftp-find-file from vax over to Sun.
 > save-some-buffers USUALLY does an automatic ftp-write-file with normal y/yes
 > Q & A session.
 > after M-x c-mode on the file save-some-bufers / save-buffer no longer 'knows'
 > that the file has been ftp'd and does do an automatic ftp-write-file.
 > Is there a variable somewhere? Or does ftp not work in this mode for some 
 > reason? Returning to the original mode does not solve the problem.

This happens becuase most major modes distributed with Emacs, C
mode included, call kill-all-local-variables, which clears away
the values of most local variables.  This makes Emacs forget the local
value of write-file-hooks in the FTP'd file buffer, and thus forget to
save the buffer via FTP.

Why is kill-all-local-variables called at the beginning of major modes?
This causes problems with minor modes that need to linger across major mode
changes.  I wish those calls to kill-all-local-variables would go away in
v19.  Or sooner.
Technical Details
Message-ID: <120552@uunet.UU.NET>
Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!UUNET.UU.NET!kyle
References: <1800@hslrswi.hasler.ascom.ch>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fb2f1,ac5fe25ca165279c,start
X-Google-Attributes: gidfb2f1,public
X-Google-ArrivalTime: 1991-01-29 12:36:28 PST
Path: arc1-ca.pugleaf.net!gmdzi!unido!mcsun!uunet!tut.cis.ohio-state.edu!UUNET.UU.NET!kyle
From: kyle@UUNET.UU.NET (Kyle Jones)
Newsgroups: gnu.emacs.bug
Subject: Re: ftp-write-file/problems
Message-ID: <120552@uunet.UU.NET>
Date: 29 Jan 91 20:36:28 GMT
References: <1800@hslrswi.hasler.ascom.ch>
Sender: daemon@tut.cis.ohio-state.edu
Followup-To: gnu.emacs.help
Distribution: gnu
Organization: UUNET Communications Services, Falls Church, VA
Lines: 20
Approved: bug-gnu-emacs@prep.ai.mit.edu