diff --git a/mod/silverbox/memcached.c b/mod/silverbox/memcached.c
index 28f1e97325ab5645f484320da5eb83ffeb7f8dfa..f8a5ca1268f48e70cb8516204b92734b5c9c9e7b 100644
--- a/mod/silverbox/memcached.c
+++ b/mod/silverbox/memcached.c
@@ -1206,7 +1206,7 @@ case 12:
 			fiber_register_cleanup((void *)txn_cleanup, txn);
 			stat_collect(stat_base, MEMC_GET, 1);
 			stats.cmd_get++;
-			say_debug("ensuring space for %i keys", keys_count);
+			say_debug("ensuring space for %"PRI_SZ" keys", keys_count);
 			iov_ensure(keys_count * 5 + 1);
 			while (keys_count-- > 0) {
 				struct box_tuple *tuple;
diff --git a/mod/silverbox/memcached.rl b/mod/silverbox/memcached.rl
index 640e63786a6e674cd623c7caf533a1c81ff0cc7d..28c64356916a3da5cc1c312e216b0a60a477cbf9 100644
--- a/mod/silverbox/memcached.rl
+++ b/mod/silverbox/memcached.rl
@@ -382,7 +382,7 @@ memcached_dispatch(struct box_txn *txn)
 			fiber_register_cleanup((void *)txn_cleanup, txn);
 			stat_collect(stat_base, MEMC_GET, 1);
 			stats.cmd_get++;
-			say_debug("ensuring space for %i keys", keys_count);
+			say_debug("ensuring space for %"PRI_SZ" keys", keys_count);
 			iov_ensure(keys_count * 5 + 1);
 			while (keys_count-- > 0) {
 				struct box_tuple *tuple;