[dia] [warningectomy] format '%d' expects argument of type 'int'
- From: Hans Breuer <hans src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dia] [warningectomy] format '%d' expects argument of type 'int'
- Date: Fri, 5 Sep 2014 15:48:56 +0000 (UTC)
commit 4639207e8dd477d5687b27a7bace62bc3b6d39b1
Author: Hans Breuer <hans breuer org>
Date: Fri Sep 5 16:05:10 2014 +0200
[warningectomy] format '%d' expects argument of type 'int'
message.c: In function 'dia_log_message':
message.c:334:3: warning: format '%d' expects argument of type 'int', but argument 4 has type 'gulong'
[-Wformat=]
g_message ("%02d:%02d:%02d.%03d - %s", h, m, s, ms/1000, log);
^
message.c:334:3: warning: format '%d' expects argument of type 'int', but argument 5 has type 'gulong'
[-Wformat=]
message.c:334:3: warning: format '%d' expects argument of type 'int', but argument 6 has type 'gulong'
[-Wformat=]
message.c:334:3: warning: format '%d' expects argument of type 'int', but argument 7 has type 'long
unsigned int' [-Wformat=]
lib/message.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/lib/message.c b/lib/message.c
index 6fd98c6..149d454 100644
--- a/lib/message.c
+++ b/lib/message.c
@@ -331,6 +331,6 @@ dia_log_message (const char *format, ...)
s = t % 60; t = (t - s) / 60;
m = t % 60; t = (t - m) / 60;
h = t;
- g_message ("%02d:%02d:%02d.%03d - %s", h, m, s, ms/1000, log);
+ g_message ("%02d:%02d:%02d.%03d - %s", (int)h, (int)m, (int)s, (int)(ms/1000), log);
g_free (log);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]