Commit 3bb4641b authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

FlexeLinting: Avoid cpp macro argument names inside strings

parent 8e779852
...@@ -41,13 +41,13 @@ ...@@ -41,13 +41,13 @@
#include "vqueue.h" #include "vqueue.h"
#include "vsb.h" #include "vsb.h"
#define VTC_CHECK_NAME(vl, name, type, chr) \ #define VTC_CHECK_NAME(vl, nm, type, chr) \
do { \ do { \
AN(name); \ AN(nm); \
if (*(name) != chr) \ if (*(nm) != chr) \
vtc_fatal(vl, \ vtc_fatal(vl, \
type " name must start with '%c' (got %s)", \ type " name must start with '%c' (got %s)", \
chr, name); \ chr, nm); \
} while (0) } while (0)
struct vtclog; struct vtclog;
......
...@@ -840,12 +840,12 @@ receive_frame(void *priv) ...@@ -840,12 +840,12 @@ receive_frame(void *priv)
return (NULL); return (NULL);
} }
#define STRTOU32(n, s, p, v, c) \ #define STRTOU32(n, ss, p, v, c) \
do { \ do { \
n = strtoul(s, &p, 0); \ n = strtoul(ss, &p, 0); \
if (*p != '\0') \ if (*p != '\0') \
vtc_fatal(v, "%s takes an integer as argument" \ vtc_fatal(v, "%s takes an integer as argument" \
"(found %s)", c, s); \ "(found %s)", c, ss); \
} while (0) } while (0)
#define STRTOU32_CHECK(n, sp, p, v, c, l) \ #define STRTOU32_CHECK(n, sp, p, v, c, l) \
...@@ -2336,7 +2336,7 @@ cmd_rxpush(CMD_ARGS) ...@@ -2336,7 +2336,7 @@ cmd_rxpush(CMD_ARGS)
if (s->frame->type != TYPE_ ## upctype) \ if (s->frame->type != TYPE_ ## upctype) \
vtc_fatal(vl, "Received frame of type %d " \ vtc_fatal(vl, "Received frame of type %d " \
"is invalid for %s", \ "is invalid for %s", \
s->frame->type, "rx ## lctype"); \ s->frame->type, "rx" #lctype); \
} }
/* SECTION: stream.spec.prio_rxprio rxprio /* SECTION: stream.spec.prio_rxprio rxprio
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment