unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Ken Brown <kbrown@cornell.edu>
Cc: 23615@debbugs.gnu.org
Subject: bug#23615: 25.1.50; Which platforms can safely use getsockopt(,,SO_ERROR,,)?
Date: Wed, 25 May 2016 19:24:45 +0300	[thread overview]
Message-ID: <8337p63y2a.fsf@gnu.org> (raw)
In-Reply-To: <df77e012-2c07-eef7-6324-bd2ad99c783c@cornell.edu> (message from Ken Brown on Tue, 24 May 2016 20:26:13 -0400)

> From: Ken Brown <kbrown@cornell.edu>
> Date: Tue, 24 May 2016 20:26:13 -0400
> 
> There are two places in process.c where getsockopt(,,SO_ERROR,,) is
> used to check the status of a socket connection attempt.  The first is
> at line 3289, where it is done on all platforms except MS Windows.  The
> second is at line 5500, where it is done only on GNU/Linux:

FYI, the first instance is ifdef'ed away for Windows because we can
never have EINTR on Windows, and the surrounding code that handles
that case is tricky to get to compile on Windows (since we override
the definitions of FD_* macros with our own).  MS-Windows does support
SO_ERROR.

> It would be better to use it on as many platforms as possible, since
> it's much more likely to give the real reason for a connection failure
> than the "error slippage" method.

Perhaps you or someone could write a small test program, and then
people here could run it various platforms and provide feedback.





  reply	other threads:[~2016-05-25 16:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-25  0:26 bug#23615: 25.1.50; Which platforms can safely use getsockopt(,,SO_ERROR,,)? Ken Brown
2016-05-25 16:24 ` Eli Zaretskii [this message]
2016-05-25 19:21   ` Ken Brown
2016-05-28 12:57     ` Eli Zaretskii
2016-05-28 17:18       ` Ken Brown
2016-05-28 17:48         ` Eli Zaretskii
2016-06-02 16:00 ` Paul Eggert
2016-06-02 17:17   ` Ken Brown
2016-06-02 17:55     ` Ken Brown
2016-06-02 18:55       ` Ken Brown
2016-06-10 12:38         ` Ken Brown
2016-06-10 17:48           ` Paul Eggert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8337p63y2a.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=23615@debbugs.gnu.org \
    --cc=kbrown@cornell.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).