diff --git a/buffer.c b/buffer.c index e9bdbb7..c11b67f 100644 --- a/buffer.c +++ b/buffer.c @@ -338,12 +338,13 @@ buffer_clear(buffer_t *self) { void buffer_print(buffer_t *self) { + int i; size_t len = self->len; printf("\n "); // hex - for (int i = 0; i < len; ++i) { + for (i = 0; i < len; ++i) { printf(" %02x", self->alloc[i]); if ((i + 1) % 8 == 0) printf("\n "); }