Powered by Linux
[PATCH 2/3] check_kernel_printf.c: %pj ended up being %pG — Semantic Matching Tool

[PATCH 2/3] check_kernel_printf.c: %pj ended up being %pG

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Rasmus Villemoes <rv@xxxxxxxxxxxxxxxxxx>
---
 check_kernel_printf.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/check_kernel_printf.c b/check_kernel_printf.c
index a8eb1d4..57e6ffb 100644
--- a/check_kernel_printf.c
+++ b/check_kernel_printf.c
@@ -614,26 +614,26 @@ static void flag_string(const char *fmt, struct symbol *type, struct symbol *bas
 {
 	static struct typedef_lookup gfp = { .name = "gfp_t" };
 
-	assert(fmt[0] == 'j');
+	assert(fmt[0] == 'G');
 	if (!isalnum(fmt[1])) {
-		sm_msg("error: %%pj must be followed by one of [gpv]");
+		sm_msg("error: %%pG must be followed by one of [gpv]");
 		return;
 	}
 	switch (fmt[1]) {
 	case 'p':
 	case 'v':
 		if (basetype != &ulong_ctype)
-			sm_msg("error: '%%pj%c' expects argument of type 'unsigned long *', argument %d has type '%s'",
+			sm_msg("error: '%%pG%c' expects argument of type 'unsigned long *', argument %d has type '%s'",
 				fmt[1], vaidx, type_to_str(type));
 		break;
 	case 'g':
 		typedef_lookup(&gfp);
 		if (basetype != gfp.sym)
-			sm_msg("error: '%%pjg' expects argument of type 'gfp_t *', argument %d has type '%s'",
+			sm_msg("error: '%%pGg' expects argument of type 'gfp_t *', argument %d has type '%s'",
 				vaidx, type_to_str(type));
 		break;
 	default:
-		sm_msg("error: '%%pj' must be followed by one of [gpv]");
+		sm_msg("error: '%%pG' must be followed by one of [gpv]");
 	}
 }
 
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe smatch" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux