static void
print_common_flags(struct iocb *iocb)
{
-#if HAVE_STRUCT_IOCB_U_C_FLAGS
+#ifdef HAVE_STRUCT_IOCB_U_C_FLAGS
if (iocb->u.c.flags & IOCB_RESFD)
tprintf(", resfd=%d", iocb->u.c.resfd);
if (iocb->u.c.flags & ~IOCB_RESFD)
/* a refers to the lower numbered u_arg,
* b refers to the higher numbered u_arg
*/
-#if HAVE_LITTLE_ENDIAN_LONG_LONG
+#ifdef HAVE_LITTLE_ENDIAN_LONG_LONG
# define LONG_LONG(a,b) \
((long long)((unsigned long long)(unsigned)(a) | ((unsigned long long)(b)<<32)))
#else
tprints("}");
}
-#if HAVE_SENDMSG
+#ifdef HAVE_SENDMSG
# ifndef SCM_SECURITY
# define SCM_SECURITY 0x03
# endif
tprintf("st_ctime=%s",
sprinttime(cast ? (time_t) (int) statbuf->st_ctime:
(time_t) statbuf->st_ctime));
-#if HAVE_STRUCT_STAT_ST_FLAGS
+#ifdef HAVE_STRUCT_STAT_ST_FLAGS
tprintf(", st_flags=%u", (unsigned int) statbuf->st_flags);
#endif
-#if HAVE_STRUCT_STAT_ST_FSTYPE
+#ifdef HAVE_STRUCT_STAT_ST_FSTYPE
tprintf(", st_fstype=%.*s",
(int) sizeof statbuf->st_fstype, statbuf->st_fstype);
#endif
-#if HAVE_STRUCT_STAT_ST_GEN
+#ifdef HAVE_STRUCT_STAT_ST_GEN
tprintf(", st_gen=%u", (unsigned int) statbuf->st_gen);
#endif
tprints("}");
} else if (func == sys_readv) {
dumpiov(tcp, tcp->u_arg[2], tcp->u_arg[1]);
return;
-#if HAVE_SENDMSG
+#ifdef HAVE_SENDMSG
} else if (func == sys_recvmsg) {
dumpiov_in_msghdr(tcp, tcp->u_arg[1]);
return;
dumpstr(tcp, tcp->u_arg[1], tcp->u_arg[2]);
else if (func == sys_writev)
dumpiov(tcp, tcp->u_arg[2], tcp->u_arg[1]);
-#if HAVE_SENDMSG
+#ifdef HAVE_SENDMSG
else if (func == sys_sendmsg)
dumpiov_in_msghdr(tcp, tcp->u_arg[1]);
else if (func == sys_sendmmsg)
#include "defs.h"
#include <sys/param.h>
#include <fcntl.h>
-#if HAVE_SYS_XATTR_H
+#ifdef HAVE_SYS_XATTR_H
# include <sys/xattr.h>
#endif
#include <sys/uio.h>
static char *
getfdproto(struct tcb *tcp, int fd, char *buf, unsigned bufsize)
{
-#if HAVE_SYS_XATTR_H
+#ifdef HAVE_SYS_XATTR_H
ssize_t r;
char path[sizeof("/proc/%u/fd/%u") + 2 * sizeof(int)*3];