summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2014-03-12 19:13:32 +0100
committerGravatar Martin Szulecki2014-03-12 19:13:32 +0100
commit02f049ae8e49abe09433c8fd850e6cae423bd05e (patch)
tree9808d70b9da22974e43e9910c7e7912c6399d774 /src
parent4d0ed22cf327a9b9925d43f98e435861cc2e7d22 (diff)
downloadlibusbmuxd-02f049ae8e49abe09433c8fd850e6cae423bd05e.tar.gz
libusbmuxd-02f049ae8e49abe09433c8fd850e6cae423bd05e.tar.bz2
socket: Fix compiler warning due to unused variable
Diffstat (limited to 'src')
-rw-r--r--src/socket.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/socket.c b/src/socket.c
index fe7d06c..ebc77e3 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -55,7 +55,9 @@ int socket_create_unix(const char *filename)
struct sockaddr_un name;
int sock;
size_t size;
+#ifdef SO_NOSIGPIPE
int yes = 1;
+#endif
// remove if still present
unlink(filename);
@@ -111,7 +113,9 @@ int socket_connect_unix(const char *filename)
int sfd = -1;
size_t size;
struct stat fst;
+#ifdef SO_NOSIGPIPE
int yes = 1;
+#endif
// check if socket file exists...
if (stat(filename, &fst) != 0) {