From 0cacb485feeb5318bd09b013833ca6e9026a5cc0 Mon Sep 17 00:00:00 2001 From: Matt Stancliff Date: Mon, 5 Jan 2015 12:26:40 -0500 Subject: Fix sds building with C++ These should really just be macros to shut up our type system. --- sds.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sds.h') diff --git a/sds.h b/sds.h index 26f84e3..b53f24d 100644 --- a/sds.h +++ b/sds.h @@ -45,12 +45,12 @@ struct sdshdr { }; static inline size_t sdslen(const sds s) { - struct sdshdr *sh = (void*)(s-sizeof *sh); + struct sdshdr *sh = (struct sdshdr *)(s-sizeof *sh); return sh->len; } static inline size_t sdsavail(const sds s) { - struct sdshdr *sh = (void*)(s-sizeof *sh); + struct sdshdr *sh = (struct sdshdr *)(s-sizeof *sh); return sh->free; } -- cgit v1.2.3