瀏覽代碼

* Compile warning fixes

Bryan Drewery 16 年之前
父節點
當前提交
f241be93ff
共有 2 個文件被更改,包括 3 次插入3 次删除
  1. 2 2
      src/binary.c
  2. 1 1
      src/main.c

+ 2 - 2
src/binary.c

@@ -215,7 +215,7 @@ bin_checksum(const char *fname, int todo)
       /* Now copy in our encrypted settings struct */
       memcpy(&outmap[newpos], &settings.hash, SIZE_PACK);
 #ifdef DEBUG
-      sdprintf(STR("writing pack: %d\n"), SIZE_PACK);
+      sdprintf(STR("writing pack: %zu\n"), SIZE_PACK);
 #endif
     } else {
       /* Just copy the original pack data to the new binary */
@@ -228,7 +228,7 @@ bin_checksum(const char *fname, int todo)
       /* Copy in the encrypted conf data */
       memcpy(&outmap[newpos], &settings.DYNAMIC_HEADER, SIZE_CONF);
 #ifdef DEBUG
-      sdprintf(STR("writing conf: %d\n"), SIZE_CONF);
+      sdprintf(STR("writing conf: %zu\n"), SIZE_CONF);
 #endif
     } else {
       /* Just copy the original conf data to the new binary */

+ 1 - 1
src/main.c

@@ -435,7 +435,7 @@ static void dtx_arg(int& argc, char *argv[])
 	printf(STR("%s\nBuild Date: %s (%s%lu%s)\n"), version, date, BOLD(-1), buildts, BOLD_END(-1));
         printf(STR("BuildOS: %s%s%s BuildArch: %s%s%s\n"), BOLD(-1), BUILD_OS, BOLD_END(-1), BOLD(-1), BUILD_ARCH, BOLD_END(-1));
 #ifdef DEBUG
-	printf(STR("pack: %d conf: %d settings_t: %d prefix: %d pad: %d needed padding: %d\n"), SIZE_PACK, SIZE_CONF, sizeof(settings_t), PREFIXLEN, SIZE_PAD, (16 - ((sizeof(settings_t) - sizeof(settings.padding)) % 16)) % 16);
+	printf(STR("pack: %zu conf: %zu settings_t: %zu prefix: %zu pad: %zu needed padding: %zu\n"), SIZE_PACK, SIZE_CONF, sizeof(settings_t), PREFIXLEN, SIZE_PAD, (16 - ((sizeof(settings_t) - sizeof(settings.padding)) % 16)) % 16);
 #endif
         if (settings.dynamic_initialized[0]) {
           bin_to_conf();