[Top][All Lists]

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

Re: [PATCH 2/3] Don't print "process finished" into the stderr buffer.

From: Philipp Stephani
Subject: Re: [PATCH 2/3] Don't print "process finished" into the stderr buffer.
Date: Fri, 19 Apr 2019 21:28:32 +0200

Am So., 8. Apr. 2018 um 15:13 Uhr schrieb Eli Zaretskii <address@hidden>:
> > From: Philipp Stephani <address@hidden>
> > Date: Sat, 07 Apr 2018 20:21:40 +0000
> > Cc: address@hidden, address@hidden
> >
> >  > * src/process.c (syms_of_process): Add 'ignore' symbol.
> >  > (Fmake_process): Use it as sentinel for the standard error pipe
> >  > process.
> >
> >  Why would we want that, and by default on top of that?  Please give at
> >  least some rationale behind this change.
> >
> > Neither the manual not the docstring for `make-process' specify that Emacs 
> > prints "Process foo stderr
> > finished" at the end of the standard error buffer, so that message 
> > shouldn't be printed.
> That assumes that the documentation is correct and the code isn't; it
> could be the other way around.

Sure. My opinion is that the documentation is correct (albeit
incomplete), and the code is slightly buggy.

> But I'm guessing that the current behavior was unexpected for some
> reason, and that's why you looked in the documentation.  If the guess
> is correct, could you describe why it was unexpected/unwanted?

It's unexpected that Emacs writes something. This is an instance of
the general case that by default you expect nothing to happen instead
of something, unless you request the "something". For example, after
$ echo foo > bar
would you expect that the file "bar" contains content other than
"foo\n" because the shell decides to write additional text before
closing redirections? This is the same thing.
The documentation for make-process doesn't state that if :stderr is a
buffer, make-process creates a pipe process with the default sentinel;
rather it treats that pipe process as implementation detail (which is
OK-ish), so users don't expect the default sentinel to run for the
stderr buffer.

reply via email to

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