strace/ipc_defs.h
Dmitry V. Levin d6c71dd061 Fix preprocessor indentation
Indent the C preprocessor directives to reflect their nesting
using the following script:

$ cppi -l $(git grep -El '^[[:space:]]*#[[:space:]]*(if|ifdef|ifndef|elif|else|endif|define|pragma)[[:space:]]' |grep -v '\.sh$') |while read f; do
	cppi < "$f" > "$f".cppi; mv "$f".cppi "$f"
done
2018-12-30 15:35:21 +00:00

34 lines
719 B
C

/*
* Copyright (c) 2003 Roland McGrath <roland@redhat.com>
* Copyright (c) 2003-2018 The strace developers.
* All rights reserved.
*
* SPDX-License-Identifier: LGPL-2.1-or-later
*/
#ifndef STRACE_IPC_DEFS_H
# define STRACE_IPC_DEFS_H
# ifdef HAVE_SYS_IPC_H
# include <sys/ipc.h>
# elif defined HAVE_LINUX_IPC_H
# include <linux/ipc.h>
/* While glibc uses __key, the kernel uses key. */
# define __key key
# endif
# if !defined IPC_64
# define IPC_64 0x100
# endif
# define PRINTCTL(flagset, arg, dflt) \
do { \
if ((arg) & IPC_64) { \
print_xlat(IPC_64); \
tprints("|"); \
} \
printxval((flagset), (arg) & ~IPC_64, dflt); \
} while (0)
#endif /* !STRACE_IPC_DEFS_H */