1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
Author: Andreas Beckmann <anbe@debian.org>
Description: fix building with -Werror=format-security
--- a/main.c
+++ b/main.c
@@ -657,7 +657,7 @@ int tcmur_get_time(struct tcmu_device *d
ret = clock_gettime(CLOCK_MONOTONIC_COARSE, time);
if (!ret) {
- tcmu_dev_dbg(dev, "Current time %lu secs.\n", time->tv_sec);
+ tcmu_dev_dbg(dev, "Current time %llu secs.\n", (long long unsigned int)(time->tv_sec));
return 0;
}
@@ -700,9 +700,9 @@ static bool get_next_cmd_timeout(struct
tmo->tv_sec = 0;
}
- tcmu_dev_dbg(dev, "Next cmd id %hu timeout in %lu secs. Current time %lu. Start time %lu\n",
- tcmur_cmd->lib_cmd->cmd_id, tmo->tv_sec,
- curr_time->tv_sec, tcmur_cmd->start_time.tv_sec);
+ tcmu_dev_dbg(dev, "Next cmd id %hu timeout in %llu secs. Current time %llu. Start time %llu\n",
+ tcmur_cmd->lib_cmd->cmd_id, (long long unsigned int)(tmo->tv_sec),
+ (long long unsigned int)(curr_time->tv_sec), (long long unsigned int)(tcmur_cmd->start_time.tv_sec));
break;
}
pthread_spin_unlock(&rdev->lock);
|