summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2011-03-24 15:40:45 +1100
committerAndrew Tridgell <tridge@samba.org>2011-03-25 04:37:06 +0100
commit37261928bec145f4cbd85f3e409063563c00ac9e (patch)
treebc2ad7debb50a14a35d2839417f9d6e577b9837e
parentaaae4123b9bcdf0a3d5d006fcb7daf10a1d95fbc (diff)
downloadsamba-37261928bec145f4cbd85f3e409063563c00ac9e.tar.gz
samba-37261928bec145f4cbd85f3e409063563c00ac9e.tar.bz2
samba-37261928bec145f4cbd85f3e409063563c00ac9e.zip
s3-includes: fixed CONST_DISCARD() to actually discard const
a cast is not enough Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
-rw-r--r--source3/include/includes.h2
1 files changed, 1 insertions, 1 deletions
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_;