unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#29454: wait_reading_process_output duplication
@ 2017-11-26  9:45 Charles A. Roelli
  2017-11-26 15:54 ` Eli Zaretskii
  0 siblings, 1 reply; 3+ messages in thread
From: Charles A. Roelli @ 2017-11-26  9:45 UTC (permalink / raw)
  To: 29454

Looks like these two blocks are duplicated in
wait_reading_process_output in process.c:

5628 #ifdef WINDOWSNT
5629 	      /* FIXME: Is this special case still needed?  */
5630 	      /* Note that we cannot distinguish between no input
5631 		 available now and a closed pipe.
5632 		 With luck, a closed pipe will be accompanied by
5633 		 subprocess termination and SIGCHLD.  */
5634 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
5635 		       && !PIPECONN_P (proc))
5636 		;
5637 #endif

5664 	      /* If we can detect process termination, don't consider the
5665 		 process gone just because its pipe is closed.  */
5666 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
5667 		       && !PIPECONN_P (proc))
5668 		;

Can the first be deleted?





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#29454: wait_reading_process_output duplication
  2017-11-26  9:45 bug#29454: wait_reading_process_output duplication Charles A. Roelli
@ 2017-11-26 15:54 ` Eli Zaretskii
  2017-11-26 19:44   ` Charles A. Roelli
  0 siblings, 1 reply; 3+ messages in thread
From: Eli Zaretskii @ 2017-11-26 15:54 UTC (permalink / raw)
  To: Charles A. Roelli; +Cc: 29454

> Date: Sun, 26 Nov 2017 10:45:53 +0100
> From: charles@aurox.ch (Charles A. Roelli)
> 
> Looks like these two blocks are duplicated in
> wait_reading_process_output in process.c:
> 
> 5628 #ifdef WINDOWSNT
> 5629 	      /* FIXME: Is this special case still needed?  */
> 5630 	      /* Note that we cannot distinguish between no input
> 5631 		 available now and a closed pipe.
> 5632 		 With luck, a closed pipe will be accompanied by
> 5633 		 subprocess termination and SIGCHLD.  */
> 5634 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
> 5635 		       && !PIPECONN_P (proc))
> 5636 		;
> 5637 #endif
> 
> 5664 	      /* If we can detect process termination, don't consider the
> 5665 		 process gone just because its pipe is closed.  */
> 5666 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
> 5667 		       && !PIPECONN_P (proc))
> 5668 		;
> 
> Can the first be deleted?

Yes.  (The second was originally conditioned on SIGCHLD, which is why
it was separate.)

Thanks.





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#29454: wait_reading_process_output duplication
  2017-11-26 15:54 ` Eli Zaretskii
@ 2017-11-26 19:44   ` Charles A. Roelli
  0 siblings, 0 replies; 3+ messages in thread
From: Charles A. Roelli @ 2017-11-26 19:44 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 29454-done

> Date: Sun, 26 Nov 2017 17:54:00 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> CC: 29454@debbugs.gnu.org
> Reply-to: Eli Zaretskii <eliz@gnu.org>
> 
> > Date: Sun, 26 Nov 2017 10:45:53 +0100
> > From: charles@aurox.ch (Charles A. Roelli)
> > 
> > Looks like these two blocks are duplicated in
> > wait_reading_process_output in process.c:
> > 
> > 5628 #ifdef WINDOWSNT
> > 5629 	      /* FIXME: Is this special case still needed?  */
> > 5630 	      /* Note that we cannot distinguish between no input
> > 5631 		 available now and a closed pipe.
> > 5632 		 With luck, a closed pipe will be accompanied by
> > 5633 		 subprocess termination and SIGCHLD.  */
> > 5634 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
> > 5635 		       && !PIPECONN_P (proc))
> > 5636 		;
> > 5637 #endif
> > 
> > 5664 	      /* If we can detect process termination, don't consider the
> > 5665 		 process gone just because its pipe is closed.  */
> > 5666 	      else if (nread == 0 && !NETCONN_P (proc) && !SERIALCONN_P (proc)
> > 5667 		       && !PIPECONN_P (proc))
> > 5668 		;
> > 
> > Can the first be deleted?
> 
> Yes.  (The second was originally conditioned on SIGCHLD, which is why
> it was separate.)
> 
> Thanks.

Thanks, it's pushed to master.

  commit 6ec5d497b6623e612ca6936ac848234725d4fc61
  Date:   Sun Nov 26 20:18:54 2017 +0100

  * src/process.c (wait_reading_process_output): Deduplicate check.

  (Bug#29454)





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-11-26 19:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-26  9:45 bug#29454: wait_reading_process_output duplication Charles A. Roelli
2017-11-26 15:54 ` Eli Zaretskii
2017-11-26 19:44   ` Charles A. Roelli

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).