printf: handle unsigned modifier for long long
authorAurélien Zanelli <aurelien.zanelli@parrot.com>
Tue, 3 Feb 2015 15:12:32 +0000 (16:12 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Thu, 12 Mar 2015 15:23:20 +0000 (15:23 +0000)
Otherwise, an unsigned integer will be displayed as a signed one if we
use internal print, ie HAVE_LONG_LONG_FORMAT is not defined.

https://bugzilla.gnome.org/show_bug.cgi?id=746096

gst/printf/vasnprintf.c

index 7f3d9e2..b40fc09 100644 (file)
@@ -121,6 +121,11 @@ print_long_long (char *buf,
       digits = upper;
       negative = FALSE;
       break;
+    case 'u':
+      base = 10;
+      digits = lower;
+      negative = FALSE;
+      break;
     default:
       base = 10;
       digits = lower;