This commit was generated by cvs2svn to compensate for changes in r5086,
[chise/xemacs-chise.git] / src / process-unix.c
index d50028e..df7e824 100644 (file)
@@ -1288,7 +1288,7 @@ unix_send_process (Lisp_Object proc, struct lstream* lstream)
 
       while (1)
        {
-         ssize_t writeret;
+         Lstream_data_count writeret;
 
          chunklen = Lstream_read (lstream, chunkbuf, 512);
          if (chunklen <= 0)
@@ -1543,9 +1543,9 @@ unix_kill_child_process (Lisp_Object proc, int signo,
   if (EMACS_KILLPG (pgid, signo) == -1)
     {
       /* It's not an error if our victim is already dead.
-         And we can't rely on the result of killing a zombie, since
-         XPG 4.2 requires that killing a zombie fail with ESRCH,
-         while FIPS 151-2 requires that it succeeds! */
+        And we can't rely on the result of killing a zombie, since
+        XPG 4.2 requires that killing a zombie fail with ESRCH,
+        while FIPS 151-2 requires that it succeeds! */
 #ifdef ESRCH
       if (errno != ESRCH)
 #endif
@@ -1587,7 +1587,11 @@ unix_canonicalize_host_name (Lisp_Object host)
 
   xzero (hints);
   hints.ai_flags = AI_CANONNAME;
+#ifdef IPV6_CANONICALIZE
   hints.ai_family = AF_UNSPEC;
+#else
+  hints.ai_family = PF_INET;
+#endif
   hints.ai_socktype = SOCK_STREAM;
   hints.ai_protocol = 0;
   LISP_STRING_TO_EXTERNAL (host, ext_host, Qnative);
@@ -1764,6 +1768,7 @@ unix_open_network_stream (Lisp_Object name, Lisp_Object host, Lisp_Object servic
 
            failed_connect = 1;
            close (s);
+           s = -1;
 
            speed_up_interrupts ();