4
0
Эх сурвалжийг харах

cpghum: Fix printf of size_t variable

Signed-off-by: Bin Liu <bliu@suse.com>
Reviewed-by: Jan Friesse <jfriesse@redhat.com>
(cherry picked from commit c144dba6223a41d2d8416a1c6d43b2bcef67a94a)
Bin Liu 8 жил өмнө
parent
commit
51425f3fb5
1 өөрчлөгдсөн 2 нэмэгдсэн , 2 устгасан
  1. 2 2
      test/cpghum.c

+ 2 - 2
test/cpghum.c

@@ -123,9 +123,9 @@ static void cpg_bm_deliver_fn (
 	// Basic check, packets should all be the right size
 	// Basic check, packets should all be the right size
 	if (g_write_size && (msg_len != g_write_size)) {
 	if (g_write_size && (msg_len != g_write_size)) {
 		length_errors++;
 		length_errors++;
-		fprintf(stderr, "%s: message sizes don't match. got %lu, expected %u\n", group_name->value, msg_len, g_write_size);
+		fprintf(stderr, "%s: message sizes don't match. got %zu, expected %u\n", group_name->value, msg_len, g_write_size);
 		if (do_syslog) {
 		if (do_syslog) {
-			syslog(LOG_ERR, "%s: message sizes don't match. got %lu, expected %u\n", group_name->value, msg_len, g_write_size);
+			syslog(LOG_ERR, "%s: message sizes don't match. got %zu, expected %u\n", group_name->value, msg_len, g_write_size);
 		}
 		}
 	}
 	}