From 37261928bec145f4cbd85f3e409063563c00ac9e Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 24 Mar 2011 15:40:45 +1100 Subject: s3-includes: fixed CONST_DISCARD() to actually discard const a cast is not enough Pair-Programmed-With: Andrew Bartlett --- source3/include/includes.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/include') diff --git a/source3/include/includes.h b/source3/include/includes.h index 7d98cd583a..96560e4f5f 100644 --- a/source3/include/includes.h +++ b/source3/include/includes.h @@ -752,7 +752,7 @@ ssize_t readahead(int fd, off64_t offset, size_t count); #endif #ifndef CONST_DISCARD -#define CONST_DISCARD(type, ptr) ((type) ((void *) (ptr))) +#define CONST_DISCARD(type, ptr) discard_const_p(type, ptr) #endif void dump_core(void) _NORETURN_; -- cgit