[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SI
From: |
Dan Nicolaescu |
Subject: |
Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM |
Date: |
Fri, 23 Jan 2009 12:33:19 -0800 (PST) |
Eli Zaretskii <address@hidden> writes:
> > From: Tassilo Horn <address@hidden>
> > Cc: Stefan Monnier <address@hidden>, address@hidden
> > Date: Fri, 23 Jan 2009 16:58:03 +0100
> >
> > Init or start-stop-daemon do that.
> >
> > > Why can't they use SIGUSRn?
> >
> > Because SIGUSRn has different meanings across applications, so the only
> > reliable way to terminate a program is "kill <pid>" which send a
> > SIGTERM.
>
> You can run your own script when the machine is shut down, can't you?
> Then have that script deliver a SIGUSRn signal to Emacs and wait a few
> moments for it to shut down peacefully.
IMHO we should not teach users to even do that.
The safest thing to do is run
emacsclient --eval "(save-buffers-kill-emacs)".
Relying on things getting saved properly on SIGTERM/SIGUSR* is just not a good
idea.
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, (continued)
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Tassilo Horn, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Eli Zaretskii, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, David De La Harpe Golden, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Eli Zaretskii, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Tassilo Horn, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Lennart Borgman, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Tassilo Horn, 2009/01/24
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Eli Zaretskii, 2009/01/24
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Miles Bader, 2009/01/24
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Eli Zaretskii, 2009/01/24
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM,
Dan Nicolaescu <=
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Eli Zaretskii, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Jason Rumney, 2009/01/23
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Miles Bader, 2009/01/24
- Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, Richard M Stallman, 2009/01/22
Re: Functions in kill-emacs-hook aren't run if emacs gets killed with SIGTERM, grischka, 2009/01/23