emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/src/process.c


From: Pavel Janík
Subject: [Emacs-diffs] Changes to emacs/src/process.c
Date: Mon, 18 Mar 2002 13:21:25 -0500

Index: emacs/src/process.c
diff -c emacs/src/process.c:1.358 emacs/src/process.c:1.359
*** emacs/src/process.c:1.358   Mon Mar 18 09:09:57 2002
--- emacs/src/process.c Mon Mar 18 13:21:25 2002
***************
*** 4207,4214 ****
          if (check_connect && FD_ISSET (channel, &Connecting))
            {
              struct Lisp_Process *p;
-             struct sockaddr pname;
-             int pnamelen = sizeof(pname);
  
              FD_CLR (channel, &connect_wait_mask);
              if (--num_pending_connects < 0)
--- 4207,4212 ----
***************
*** 4229,4244 ****
                  xerrno = errno;
              }
  #else
!             /* If connection failed, getpeername will fail.  */
!             xerrno = 0;
!             if (getpeername(channel, &pname, &pnamelen) < 0)
!               {
!                 /* Obtain connect failure code through error slippage.  */
!                 char dummy;
!                 xerrno = errno;
!                 if (errno == ENOTCONN && read(channel, &dummy, 1) < 0)
                    xerrno = errno;
!               }
  #endif
              if (xerrno)
                {
--- 4227,4247 ----
                  xerrno = errno;
              }
  #else
!             {
!               struct sockaddr pname;
!               int pnamelen = sizeof(pname);
! 
!               /* If connection failed, getpeername will fail.  */
!               xerrno = 0;
!               if (getpeername(channel, &pname, &pnamelen) < 0)
!                 {
!                   /* Obtain connect failure code through error slippage.  */
!                   char dummy;
                    xerrno = errno;
!                   if (errno == ENOTCONN && read(channel, &dummy, 1) < 0)
!                     xerrno = errno;
!                 }
!             }
  #endif
              if (xerrno)
                {



reply via email to

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