Browse Source

Merge branch 'maint-0.3.1'

Nick Mathewson 7 years ago
parent
commit
ff0aabc35d
2 changed files with 8 additions and 4 deletions
  1. 4 0
      changes/bug23568
  2. 4 4
      src/common/compress_zstd.c

+ 4 - 0
changes/bug23568

@@ -0,0 +1,4 @@
+  o Minor bugfixes (compilation):
+    - Fix a compilation warning when building with zstd support
+      on 32-bit platforms. Fixes bug 23568; bugfix on 0.3.1.1-alpha.
+      Found and fixed by Andreas Stieger.

+ 4 - 4
src/common/compress_zstd.c

@@ -62,10 +62,10 @@ tor_zstd_get_version_str(void)
 
   version_number = ZSTD_versionNumber();
   tor_snprintf(version_str, sizeof(version_str),
-               "%lu.%lu.%lu",
-               version_number / 10000 % 100,
-               version_number / 100 % 100,
-               version_number % 100);
+               "%d.%d.%d",
+               (int) version_number / 10000 % 100,
+               (int) version_number / 100 % 100,
+               (int) version_number % 100);
 
   return version_str;
 #else /* !(defined(HAVE_ZSTD)) */