(Fmake_network_process): Only support server sockets
authorJason Rumney <jasonr@gnu.org>
Fri, 3 May 2002 21:24:27 +0000 (21:24 +0000)
committerJason Rumney <jasonr@gnu.org>
Fri, 3 May 2002 21:24:27 +0000 (21:24 +0000)
when we can make them non-blocking.

src/process.c

index cdd9b61..d8f9c65 100644 (file)
@@ -2590,7 +2590,9 @@ usage: (make-network-process &rest ARGS)  */)
   tem = Fplist_get (contact, QCserver);
   if (!NILP (tem))
     {
-#ifdef TERM
+      /* Don't support network sockets when non-blocking mode is
+        not available, since a blocked Emacs is not useful.  */
+#if defined(TERM) || (!defined(O_NONBLOCK) && !defined(O_NDELAY))
       error ("Network servers not supported");
 #else
       is_server = 1;