emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: y-or-n-p and emacs --daemon


From: Stefan Monnier
Subject: Re: y-or-n-p and emacs --daemon
Date: Wed, 03 Dec 2008 21:16:42 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

>> Bad idea:
>> (unless (y-or-n-p "Stop me from removing all your files") 
>> /bin/rm -rf /
>> )

Such a question would be a bug that we need fixing.  Usually Emacs is
pretty consistent in asking questions in such a way that `n' is
a safe answer.

>> Ignore it, or fix it properly: so that it works like y-or-n-p when
>> using -batch.
> I don't think that would solve the problem either, since AFAIU the
> daemon might not have a user accessible terminal at all (as bug#1310).

Does someone know the reason for this problem?  E.g. it's not clear to
me why the y-or-n-p question is displayed (even though it's after
"Starting Emacs daemon", so stdout should have been closed) but the
answer is ignored (or is it?).

Ideally, either the question comes before detaching and it should then
behave as it does in -batch, or the question comes after detaching and
it should then wait for a frame to be created to display the question
in there.


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]