diff options
author | Roland McGrath <roland@redhat.com> | 2002-12-16 20:40:59 +0000 |
---|---|---|
committer | Roland McGrath <roland@redhat.com> | 2002-12-16 20:40:59 +0000 |
commit | 34e014ac7502357e599935c62c18cba564c451be (patch) | |
tree | 6c5420675a33d618e077c58674d00abf9e23741d /stream.c | |
parent | 1e85cf9cb1b0cf3773bbd361bce57379d30b4940 (diff) | |
download | strace-34e014ac7502357e599935c62c18cba564c451be.tar.gz strace-34e014ac7502357e599935c62c18cba564c451be.tar.bz2 strace-34e014ac7502357e599935c62c18cba564c451be.tar.xz |
2002-12-15 Roland McGrath <roland@redhat.com>
* configure.in: Don't check for putpmsg.
* stream.c (sys_getpmsg, sys_putpmsg): Make these conditional on
#ifdef SYS_*, rather than on HAVE_PUTPMSG.
Diffstat (limited to 'stream.c')
-rw-r--r-- | stream.c | 25 |
1 files changed, 14 insertions, 11 deletions
@@ -29,6 +29,7 @@ */ #include "defs.h" +#include <sys/syscall.h> #ifdef HAVE_POLL_H #include <poll.h> @@ -177,8 +178,7 @@ struct tcb *tcp; return RVAL_HEX | RVAL_STR; } -#ifdef HAVE_PUTPMSG - +#if defined SYS_putpmsg || defined SYS_getpmsg static struct xlat pmsgflags[] = { #ifdef MSG_HIPRI { MSG_HIPRI, "MSG_HIPRI" }, @@ -191,7 +191,9 @@ static struct xlat pmsgflags[] = { #endif { 0, NULL }, }; +#endif +#ifdef SYS_putpmsg int sys_putpmsg(tcp) struct tcb *tcp; @@ -212,7 +214,9 @@ struct tcb *tcp; } return 0; } +#endif /* SYS_putpmsg */ +#ifdef SYS_getpmsg int sys_getpmsg(tcp) struct tcb *tcp; @@ -263,8 +267,8 @@ struct tcb *tcp; } return RVAL_HEX | RVAL_STR; } +#endif /* SYS_getpmsg */ -#endif /* HAVE_PUTPMSG */ #endif /* !FREEBSD */ @@ -556,7 +560,7 @@ struct tcb *tcp; long addr; int len; { - /* We don't know how to tell if TLI (socket) or XTI + /* We don't know how to tell if TLI (socket) or XTI optmgmt is being used yet, assume TLI. */ #if defined (HAVE_OPTHDR) print_sock_optmgmt (tcp, addr, len); @@ -668,8 +672,8 @@ int len; while (0) #define COMMA() \ - do { if (c++) tprintf (", "); } while (0) - + do { if (c++) tprintf (", "); } while (0) + #define STRUCT(struct, elem, print) \ do { \ @@ -692,7 +696,7 @@ int len; while (0) #define ADDR(struct, elem) STRUCT (struct, elem, printstr) - + switch (m.type) { #ifdef T_CONN_REQ case T_CONN_REQ: /* connect request */ @@ -909,7 +913,7 @@ int len; #undef ADDR #undef COMMA #undef STRUCT - + return 0; } @@ -1064,7 +1068,7 @@ int arg; return RVAL_STR + 1; } } - + return 1; } @@ -1287,7 +1291,6 @@ int code, arg; } } -#endif /* !linux && !FREEBSD */ +#endif /* !linux && !FREEBSD */ #endif /* HAVE_SYS_STREAM_H || linux || FREEBSD */ - |