diff --git a/coders/wpg.c b/coders/wpg.c
index 411be69..29ebefe 100644
--- a/coders/wpg.c
+++ b/coders/wpg.c
@@ -598,7 +598,7 @@
             {
               (void) fprintf(stderr,
                              "\nUnsupported WPG2 unaligned token RST x=%lu, please report!\n"
-                             ,x);
+                             ,(unsigned long) x);
               return(-3);
             }
           {