summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garcia Campos <carlosgc@gnome.org>2010-04-18 18:28:34 +0200
committerCarlos Garcia Campos <carlosgc@gnome.org>2010-04-18 18:28:34 +0200
commit233babb7bf516aac10b853785b8d22c7d6fa777e (patch)
treec5a34299efd7feb137e1a7d2d04a7a0fdb626595
parentce55aa1110f3b933943a92ecd0a948d017cdb492 (diff)
Use %I64x format for DisplayHandle on Windows 64 bits
-rw-r--r--libspectre/spectre-device.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libspectre/spectre-device.c b/libspectre/spectre-device.c
index a4deac2..5267d09 100644
--- a/libspectre/spectre-device.c
+++ b/libspectre/spectre-device.c
@@ -240,10 +240,16 @@ spectre_device_render (SpectreDevice *device,
DISPLAY_LITTLEENDIAN |
#endif
DISPLAY_TOPFIRST);
+#ifdef WIN32
+#define FMT64 "I64"
+#else
+#define FMT64 "ll"
+#endif
fmt = _spectre_strdup_printf ("-sDisplayHandle=16#%s",
- sizeof (device) == 4 ? "%lx" : "%llx");
+ sizeof (device) == 4 ? "%lx" : "%"FMT64"x");
args[arg++] = dsp_handle = _spectre_strdup_printf (fmt, device);
free (fmt);
+#undef FMT64
if (rc->use_platform_fonts == FALSE)
args[arg++] = "-dNOPLATFONTS";