unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* EWOULDBLOCK and EINPROGRESS in process.c
@ 2015-03-24 18:09 Eli Zaretskii
  2015-03-24 21:25 ` Andreas Schwab
  2015-03-24 23:42 ` Paul Eggert
  0 siblings, 2 replies; 5+ messages in thread
From: Eli Zaretskii @ 2015-03-24 18:09 UTC (permalink / raw)
  To: emacs-devel

process.c has this fragment after it calls 'connect':

  #ifdef NON_BLOCKING_CONNECT
  #ifdef EINPROGRESS
	if (is_non_blocking_client && xerrno == EINPROGRESS)
	  break;
  #else  <<<<<<<<<<<<<<<<<<<<<<<<<<<<
  #ifdef EWOULDBLOCK
	if (is_non_blocking_client && xerrno == EWOULDBLOCK)
	  break;
  #endif
  #endif
  #endif

Can someone tell why we need that "#else" there?  Suppose there's a
platform that has both values defined, but only returns EWOULDBLOCK
when a non-blocking 'connect' is called -- that platform will fall
through the cracks here.

Is there any problem to replace #else with #endif here?



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

end of thread, other threads:[~2015-03-25 18:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-24 18:09 EWOULDBLOCK and EINPROGRESS in process.c Eli Zaretskii
2015-03-24 21:25 ` Andreas Schwab
2015-03-25 18:13   ` Eli Zaretskii
2015-03-24 23:42 ` Paul Eggert
2015-03-25 18:15   ` Eli Zaretskii

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).