libiscsi: Fix a format specifier

Use %lu to format unsigned long instead of %d.

This was detected by Coverity.

Signed-off-by: Bart Van Assche <bvanassche@acm.org>
This commit is contained in:
Bart Van Assche
2019-11-12 18:22:28 -08:00
parent eeb7ebaeab
commit 0ad5c2c648
2 changed files with 2 additions and 2 deletions

View File

@@ -361,7 +361,7 @@ void iscsi_decrement_iface_rr(void);
} \
} while (0)
void
void __attribute__((format(printf, 3, 4)))
iscsi_log_message(struct iscsi_context *iscsi, int level, const char *format, ...);
void

View File

@@ -289,7 +289,7 @@ iscsi_create_context(const char *initiator_name)
while (iscsi->smalloc_size < required) {
iscsi->smalloc_size <<= 1;
}
ISCSI_LOG(iscsi,5,"small allocation size is %d byte", iscsi->smalloc_size);
ISCSI_LOG(iscsi,5,"small allocation size is %lu byte", iscsi->smalloc_size);
ca = getenv("LIBISCSI_CACHE_ALLOCATIONS");
if (!ca || atoi(ca) != 0) {