svn commit: samba r10525 - in branches/SAMBA_4_0/source: build/m4 include lib/ldb/include lib/talloc

tridge at samba.org tridge at samba.org
Tue Sep 27 03:11:09 GMT 2005


Author: tridge
Date: 2005-09-27 03:11:08 +0000 (Tue, 27 Sep 2005)
New Revision: 10525

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=10525

Log:

change from AC_CHECK_TYPES() to AC_CHECK_TYPE() for intptr_t, so the
type is always available, which means we need less #ifdefs

Modified:
   branches/SAMBA_4_0/source/build/m4/rewrite.m4
   branches/SAMBA_4_0/source/include/includes.h
   branches/SAMBA_4_0/source/lib/ldb/include/includes.h
   branches/SAMBA_4_0/source/lib/talloc/config.m4


Changeset:
Modified: branches/SAMBA_4_0/source/build/m4/rewrite.m4
===================================================================
--- branches/SAMBA_4_0/source/build/m4/rewrite.m4	2005-09-27 03:09:38 UTC (rev 10524)
+++ branches/SAMBA_4_0/source/build/m4/rewrite.m4	2005-09-27 03:11:08 UTC (rev 10525)
@@ -79,7 +79,6 @@
 AC_CHECK_TYPE(ino_t,unsigned)
 AC_CHECK_TYPE(loff_t,off_t)
 AC_CHECK_TYPE(offset_t,loff_t)
-AC_CHECK_TYPES(intptr_t)
 AC_CHECK_TYPES(long long)
 
 

Modified: branches/SAMBA_4_0/source/include/includes.h
===================================================================
--- branches/SAMBA_4_0/source/include/includes.h	2005-09-27 03:09:38 UTC (rev 10524)
+++ branches/SAMBA_4_0/source/include/includes.h	2005-09-27 03:11:08 UTC (rev 10525)
@@ -162,11 +162,7 @@
   Also, please call this via the discard_const_p() macro interface, as that
   makes the return type safe.
 */
-#ifdef HAVE_INTPTR_T
 #define discard_const(ptr) ((void *)((intptr_t)(ptr)))
-#else
-#define discard_const(ptr) ((void *)(ptr))
-#endif
 #define discard_const_p(type, ptr) ((type *)discard_const(ptr))
 
 #ifndef UINT16_MAX

Modified: branches/SAMBA_4_0/source/lib/ldb/include/includes.h
===================================================================
--- branches/SAMBA_4_0/source/lib/ldb/include/includes.h	2005-09-27 03:09:38 UTC (rev 10524)
+++ branches/SAMBA_4_0/source/lib/ldb/include/includes.h	2005-09-27 03:11:08 UTC (rev 10525)
@@ -26,9 +26,5 @@
 #include "ldb_private.h"
 #include "talloc.h"
 
-#if defined(__intptr_t_defined) || defined(HAVE_INTPTR_T)
 #define discard_const(ptr) ((void *)((intptr_t)(ptr)))
-#else
-#define discard_const(ptr) ((void *)(ptr))
-#endif
 #define discard_const_p(type, ptr) ((type *)discard_const(ptr))

Modified: branches/SAMBA_4_0/source/lib/talloc/config.m4
===================================================================
--- branches/SAMBA_4_0/source/lib/talloc/config.m4	2005-09-27 03:09:38 UTC (rev 10524)
+++ branches/SAMBA_4_0/source/lib/talloc/config.m4	2005-09-27 03:11:08 UTC (rev 10525)
@@ -6,5 +6,5 @@
     AC_DEFINE(HAVE_VA_COPY,1,[Whether va_copy() is available])
 fi
 
-AC_CHECK_TYPES(intptr_t)
+AC_CHECK_TYPE(intptr_t, unsigned long long)
 AC_CHECK_HEADERS(stdint.h stdarg.h unistd.h sys/types.h)



More information about the samba-cvs mailing list