SOURCES: sylpheed-glibc.patch (NEW) - fix problem with redeclaration of SO...

lisu lisu at pld-linux.org
Wed Dec 3 10:00:11 CET 2008


Author: lisu                         Date: Wed Dec  3 09:00:11 2008 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
-  fix problem with redeclaration of SOCK_NONBLOCK previously declared in glibc's socket.h

---- Files affected:
SOURCES:
   sylpheed-glibc.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SOURCES/sylpheed-glibc.patch
diff -u /dev/null SOURCES/sylpheed-glibc.patch:1.1
--- /dev/null	Wed Dec  3 10:00:11 2008
+++ SOURCES/sylpheed-glibc.patch	Wed Dec  3 10:00:05 2008
@@ -0,0 +1,65 @@
+--- sylpheed-2.6.0rc/libsylph/socket.h~	2007-06-11 10:06:45.000000000 +0200
++++ sylpheed-2.6.0rc/libsylph/socket.h	2008-12-03 09:43:30.000000000 +0100
+@@ -46,14 +46,14 @@
+ 
+ typedef enum
+ {
+-	SOCK_NONBLOCK	= 1 << 0,
+-	SOCK_CHECK_IO	= 1 << 1
++	SYL_SOCK_NONBLOCK	= 1 << 0,
++	SYL_SOCK_CHECK_IO	= 1 << 1
+ } SockFlags;
+ 
+ #define SOCK_SET_FLAGS(flags, set)	{ (flags) |= (set); }
+ #define SOCK_UNSET_FLAGS(flags, set)	{ (flags) &= ~(set); }
+-#define SOCK_IS_NONBLOCK(flags)		((flags & SOCK_NONBLOCK) != 0)
+-#define SOCK_IS_CHECK_IO(flags)		((flags & SOCK_CHECK_IO) != 0)
++#define SOCK_IS_NONBLOCK(flags)		((flags & SYL_SOCK_NONBLOCK) !=0)
++#define SOCK_IS_CHECK_IO(flags)		((flags & SYL_SOCK_CHECK_IO) !=0)
+ 
+ typedef gint (*SockConnectFunc)		(SockInfo	*sock,
+ 					 gpointer	 data);
+--- sylpheed-2.6.0rc/libsylph/socket.c~	2008-09-19 04:10:35.000000000 +0200
++++ sylpheed-2.6.0rc/libsylph/socket.c	2008-12-03 09:48:37.000000000 +0100
+@@ -383,9 +383,9 @@
+ 	sock = sock_find_from_fd(fd);
+ 	if (sock) {
+ 		if (nonblock) {
+-			SOCK_SET_FLAGS(sock->flags, SOCK_NONBLOCK);
++			SOCK_SET_FLAGS(sock->flags, SYL_SOCK_NONBLOCK);
+ 		} else {
+-			SOCK_UNSET_FLAGS(sock->flags, SOCK_NONBLOCK);
++			SOCK_UNSET_FLAGS(sock->flags, SYL_SOCK_NONBLOCK);
+ 		}
+ 	}
+ 	debug_print("set nonblocking mode to %d\n", nonblock);
+@@ -418,9 +418,9 @@
+ 	ret = set_nonblocking_mode(sock->sock, nonblock);
+ 	if (ret == 0) {
+ 		if (nonblock) {
+-			SOCK_SET_FLAGS(sock->flags, SOCK_NONBLOCK);
++			SOCK_SET_FLAGS(sock->flags, SYL_SOCK_NONBLOCK);
+ 		} else {
+-			SOCK_UNSET_FLAGS(sock->flags, SOCK_NONBLOCK);
++			SOCK_UNSET_FLAGS(sock->flags, SYL_SOCK_NONBLOCK);
+ 		}
+ 	}
+ 
+@@ -882,7 +882,7 @@
+ 	sockinfo->hostname = g_strdup(hostname);
+ 	sockinfo->port = port;
+ 	sockinfo->state = CONN_ESTABLISHED;
+-	sockinfo->flags = SOCK_CHECK_IO;
++	sockinfo->flags = SYL_SOCK_CHECK_IO;
+ 
+ 	sock_list = g_list_prepend(sock_list, sockinfo);
+ 
+@@ -951,7 +951,7 @@
+ 	sockinfo->hostname = g_strdup(conn_data->hostname);
+ 	sockinfo->port = conn_data->port;
+ 	sockinfo->state = CONN_ESTABLISHED;
+-	sockinfo->flags = SOCK_NONBLOCK;
++	sockinfo->flags = SYL_SOCK_NONBLOCK;
+ 
+ 	sock_list = g_list_prepend(sock_list, sockinfo);
+ 
================================================================


More information about the pld-cvs-commit mailing list