From: Rusty Russell Date: Mon, 21 Mar 2011 11:48:48 +0000 (+1030) Subject: tdb2: fix arithmetic on void * pointer. X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=f2a1247955c1b376469a5e37c9583a1bbfd4dc61;hp=148c09482cd343f1c02526908a2612d327412697 tdb2: fix arithmetic on void * pointer. --- diff --git a/ccan/tdb2/io.c b/ccan/tdb2/io.c index 4ed37ca2..bb3d2192 100644 --- a/ccan/tdb2/io.c +++ b/ccan/tdb2/io.c @@ -342,7 +342,7 @@ enum TDB_ERROR tdb_write_off(struct tdb_context *tdb, static void *_tdb_alloc_read(struct tdb_context *tdb, tdb_off_t offset, tdb_len_t len, unsigned int prefix) { - void *buf; + unsigned char *buf; enum TDB_ERROR ecode; /* some systems don't like zero length malloc */