From 7d63aa5ef3c84499ddb8728c36dfe835a19711a0 Mon Sep 17 00:00:00 2001 From: "Dmitry V. Levin" Date: Thu, 28 Apr 2016 17:50:51 +0000 Subject: [PATCH] Turn printxval macro into a static inline function This is necessary for the upcoming change of xlat.val type. * defs.h (printxval): Change to static inline function. --- defs.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/defs.h b/defs.h index ef579ebe..583f7156 100644 --- a/defs.h +++ b/defs.h @@ -551,7 +551,6 @@ extern int printllval(struct tcb *, const char *, int) extern void printaddr(long); extern void printxvals(const unsigned int, const char *, const struct xlat *, ...) ATTRIBUTE_SENTINEL; -#define printxval(xlat, val, dflt) printxvals(val, dflt, xlat, NULL) extern int printargs(struct tcb *); extern int printargs_u(struct tcb *); extern int printargs_d(struct tcb *); @@ -667,6 +666,12 @@ extern void unwind_print_stacktrace(struct tcb* tcp); extern void unwind_capture_stacktrace(struct tcb* tcp); #endif +static inline void +printxval(const struct xlat *x, const unsigned int val, const char *dflt) +{ + printxvals(val, dflt, x, NULL); +} + /* Strace log generation machinery. * * printing_tcp: tcb which has incomplete line being printed right now. -- 2.50.1