dont compile msg.c on non-linux.

SVN revision: 65341
This commit is contained in:
Carsten Haitzler 2011-11-17 11:27:26 +00:00
parent 861f7bb901
commit b773e28a73
1 changed files with 25 additions and 0 deletions

View File

@ -6,6 +6,7 @@
void void
msg_recv_creds(Pulse *conn, Pulse_Tag *tag) msg_recv_creds(Pulse *conn, Pulse_Tag *tag)
{ {
#ifdef __linux__
int r; int r;
struct msghdr mh; struct msghdr mh;
struct iovec iov; struct iovec iov;
@ -36,11 +37,16 @@ msg_recv_creds(Pulse *conn, Pulse_Tag *tag)
DBG("%zu bytes left", sizeof(tag->header) - r); DBG("%zu bytes left", sizeof(tag->header) - r);
tag->pos += r; tag->pos += r;
} }
#else
conn = NULL;
tag = NULL;
#endif
} }
Eina_Bool Eina_Bool
msg_recv(Pulse *conn, Pulse_Tag *tag) msg_recv(Pulse *conn, Pulse_Tag *tag)
{ {
#ifdef __linux__
long r; long r;
struct msghdr mh; struct msghdr mh;
struct iovec iov; struct iovec iov;
@ -74,12 +80,17 @@ msg_recv(Pulse *conn, Pulse_Tag *tag)
} }
else else
tag->pos += r; tag->pos += r;
#else
conn = NULL;
tag = NULL;
#endif
return EINA_FALSE; return EINA_FALSE;
} }
void void
msg_sendmsg_creds(Pulse *conn, Pulse_Tag *tag) msg_sendmsg_creds(Pulse *conn, Pulse_Tag *tag)
{ {
#ifdef __linux__
int r; int r;
struct msghdr mh; struct msghdr mh;
struct iovec iov; struct iovec iov;
@ -118,11 +129,16 @@ msg_sendmsg_creds(Pulse *conn, Pulse_Tag *tag)
} }
else else
tag->pos += r; tag->pos += r;
#else
conn = NULL;
tag = NULL;
#endif
} }
void void
msg_send_creds(Pulse *conn, Pulse_Tag *tag) msg_send_creds(Pulse *conn, Pulse_Tag *tag)
{ {
#ifdef __linux__
int r; int r;
INF("trying to send 20 byte auth header"); INF("trying to send 20 byte auth header");
@ -135,11 +151,16 @@ msg_send_creds(Pulse *conn, Pulse_Tag *tag)
} }
else else
tag->pos += r; tag->pos += r;
#else
conn = NULL;
tag = NULL;
#endif
} }
Eina_Bool Eina_Bool
msg_send(Pulse *conn, Pulse_Tag *tag) msg_send(Pulse *conn, Pulse_Tag *tag)
{ {
#ifdef __linux__
int r; int r;
INF("trying to send %zu bytes", tag->dsize - tag->pos); INF("trying to send %zu bytes", tag->dsize - tag->pos);
@ -158,5 +179,9 @@ msg_send(Pulse *conn, Pulse_Tag *tag)
} }
else else
tag->pos += r; tag->pos += r;
#else
conn = NULL;
tag = NULL;
#endif
return EINA_FALSE; return EINA_FALSE;
} }