diff libpurple/protocols/msn/directconn.c @ 20347:04fe5601fedb

applied changes from 2762c6075c0dc52a96098c5478c5bf68cfd890a3 through 8548e491a5b470d5665cb1cf87a7b0caaa3c87a5
author Luke Schierer <lschiere@pidgin.im>
date Sun, 21 Oct 2007 04:46:33 +0000
parents 61e478573b14
children 89c7be36fd61
line wrap: on
line diff
--- a/libpurple/protocols/msn/directconn.c	Sun Oct 21 04:44:56 2007 +0000
+++ b/libpurple/protocols/msn/directconn.c	Sun Oct 21 04:46:33 2007 +0000
@@ -81,6 +81,7 @@
 create_listener(int port)
 {
 	int fd;
+	int flags;
 	const int on = 1;
 
 #if 0
@@ -156,7 +157,8 @@
 		return -1;
 	}
 
-	fcntl(fd, F_SETFL, O_NONBLOCK);
+	flags = fcntl(fd, F_GETFL);
+	fcntl(fd, F_SETFL, flags | O_NONBLOCK);
 
 	return fd;
 }