From: Matthias Clasen Date: Wed, 11 Jun 2008 22:00:06 +0000 (+0000) Subject: hex, I mean it X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=8882576e90433a9d784f498914a47c7a2a7a46f3;p=dana%2Fcg-glib.git hex, I mean it svn path=/trunk/; revision=7019 --- diff --git a/ChangeLog b/ChangeLog index 2b07f997..4dafd60c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2008-06-11 Matthias Clasen + + Bug 502511 – g_assert_cmphex prints invalid message + + * glib/gtestutils.c (g_assertion_message_cmpnum): Actually print + hex numbers in hex. + Pointed out by Tor Lillqvist + 2008-06-11 Matthias Clasen Bug 338162 – [PATCH] Use po/LINGUAS diff --git a/glib/gtestutils.c b/glib/gtestutils.c index 783856e0..23c5ae3e 100644 --- a/glib/gtestutils.c +++ b/glib/gtestutils.c @@ -1245,7 +1245,7 @@ g_assertion_message_cmpnum (const char *domain, switch (numtype) { case 'i': s = g_strdup_printf ("assertion failed (%s): (%.0Lf %s %.0Lf)", expr, arg1, cmp, arg2); break; - case 'x': s = g_strdup_printf ("assertion failed (%s): (0x%08" G_GUINT64_FORMAT " %s 0x%08" G_GUINT64_FORMAT ")", expr, (guint64) arg1, cmp, (guint64) arg2); break; + case 'x': s = g_strdup_printf ("assertion failed (%s): (0x%08" G_GINT64_MODIFIER "x %s 0x%08" G_GINT64_MODIFIER "x)", expr, (guint64) arg1, cmp, (guint64) arg2); break; case 'f': s = g_strdup_printf ("assertion failed (%s): (%.9Lg %s %.9Lg)", expr, arg1, cmp, arg2); break; /* ideally use: floats=%.7g double=%.17g */ }