From 5605b69c9898fb44018a6af713c438781a75b967 Mon Sep 17 00:00:00 2001 From: Mark Johnston Date: Sat, 21 Sep 2013 22:43:50 +0000 Subject: [PATCH] Give argtype struct names a different prefix than probe struct names. Otherwise it's possible to declare SDT probes in such a way that a name collision occurs, causing an unexpected compilation error. Approved by: re (gjb) MFC after: 1 week --- sys/sys/sdt.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/sys/sdt.h b/sys/sys/sdt.h index 820f4bba0cad..f7b58f64b649 100644 --- a/sys/sys/sdt.h +++ b/sys/sys/sdt.h @@ -160,11 +160,11 @@ SET_DECLARE(sdt_argtypes_set, struct sdt_argtype); } while (0) #define SDT_PROBE_ARGTYPE(prov, mod, func, name, num, type, xtype) \ - static struct sdt_argtype sdt_##prov##_##mod##_##func##_##name##num[1] \ + static struct sdt_argtype sdta_##prov##_##mod##_##func##_##name##num[1] \ = { { num, type, xtype, { NULL, NULL }, \ sdt_##prov##_##mod##_##func##_##name } \ }; \ - DATA_SET(sdt_argtypes_set, sdt_##prov##_##mod##_##func##_##name##num); + DATA_SET(sdt_argtypes_set, sdta_##prov##_##mod##_##func##_##name##num); #define SDT_PROBE_DEFINE0(prov, mod, func, name, sname) \ SDT_PROBE_DEFINE(prov, mod, func, name, sname)