svn commit: samba r17749 - in
branches/SAMBA_4_0/source/lib/ldb/replace: .
tridge at samba.org
tridge at samba.org
Wed Aug 23 11:31:44 GMT 2006
Author: tridge
Date: 2006-08-23 11:31:43 +0000 (Wed, 23 Aug 2006)
New Revision: 17749
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=17749
Log:
more HPUX madness
Modified:
branches/SAMBA_4_0/source/lib/ldb/replace/config.m4
branches/SAMBA_4_0/source/lib/ldb/replace/replace.c
Changeset:
Modified: branches/SAMBA_4_0/source/lib/ldb/replace/config.m4
===================================================================
--- branches/SAMBA_4_0/source/lib/ldb/replace/config.m4 2006-08-23 11:29:08 UTC (rev 17748)
+++ branches/SAMBA_4_0/source/lib/ldb/replace/config.m4 2006-08-23 11:31:43 UTC (rev 17749)
@@ -6,6 +6,7 @@
[AC_DEFINE(HAVE_COMPARISON_FN_T, 1,[Whether or not we have comparison_fn_t])])
AC_CHECK_FUNCS(strerror timegm strnlen)
+AC_CHECK_FUNCS(strtoull __strtoull strtouq strtoll __strtoll strtoq)
AC_HAVE_DECL(errno, [#include <errno.h>])
AC_CHECK_HEADERS(strings.h)
Modified: branches/SAMBA_4_0/source/lib/ldb/replace/replace.c
===================================================================
--- branches/SAMBA_4_0/source/lib/ldb/replace/replace.c 2006-08-23 11:29:08 UTC (rev 17748)
+++ branches/SAMBA_4_0/source/lib/ldb/replace/replace.c 2006-08-23 11:31:43 UTC (rev 17749)
@@ -35,3 +35,35 @@
return i;
}
#endif
+
+#ifndef HAVE_STRTOLL
+ long long int strtoll(const char *str, char **endptr, int base)
+{
+#ifdef HAVE_STRTOQ
+ return strtoq(str, endptr, base);
+#elif defined(HAVE___STRTOLL)
+ return __strtoll(str, endptr, base);
+#elif SIZEOF_LONG == SIZEOF_LONG_LONG
+ return (long long int) strtol(str, endptr, base);
+#else
+# error "You need a strtoll function"
+#endif
+}
+#endif
+
+
+#ifndef HAVE_STRTOULL
+ unsigned long long int strtoull(const char *str, char **endptr, int base)
+{
+#ifdef HAVE_STRTOUQ
+ return strtouq(str, endptr, base);
+#elif defined(HAVE___STRTOULL)
+ return __strtoull(str, endptr, base);
+#elif SIZEOF_LONG == SIZEOF_LONG_LONG
+ return (unsigned long long int) strtoul(str, endptr, base);
+#else
+# error "You need a strtoull function"
+#endif
+}
+#endif
+
More information about the samba-cvs
mailing list