svn commit: samba r22366 - in branches/SAMBA_3_0/source/lib/talloc: .

metze at samba.org metze at samba.org
Thu Apr 19 09:08:53 GMT 2007


Author: metze
Date: 2007-04-19 09:08:53 +0000 (Thu, 19 Apr 2007)
New Revision: 22366

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

Log:
sync lib/talloc/ with samba4

metze
Modified:
   branches/SAMBA_3_0/source/lib/talloc/config.mk
   branches/SAMBA_3_0/source/lib/talloc/talloc.h
   branches/SAMBA_3_0/source/lib/talloc/talloc.pc.in
   branches/SAMBA_3_0/source/lib/talloc/testsuite.c


Changeset:
Modified: branches/SAMBA_3_0/source/lib/talloc/config.mk
===================================================================
--- branches/SAMBA_3_0/source/lib/talloc/config.mk	2007-04-19 09:08:30 UTC (rev 22365)
+++ branches/SAMBA_3_0/source/lib/talloc/config.mk	2007-04-19 09:08:53 UTC (rev 22366)
@@ -11,8 +11,3 @@
 #
 # End LIBRARY LIBTALLOC
 ################################################
-
-[BINARY::TALLOC]
-OBJ_FILES = testsuite.o
-PRIVATE_DEPENDENCIES = LIBTALLOC
-INSTALLDIR = TORTUREDIR/LOCAL

Modified: branches/SAMBA_3_0/source/lib/talloc/talloc.h
===================================================================
--- branches/SAMBA_3_0/source/lib/talloc/talloc.h	2007-04-19 09:08:30 UTC (rev 22365)
+++ branches/SAMBA_3_0/source/lib/talloc/talloc.h	2007-04-19 09:08:53 UTC (rev 22366)
@@ -26,6 +26,10 @@
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */
 
+#include <stdlib.h>
+#include <stdio.h>
+#include <stdarg.h>
+
 /* this is only needed for compatibility with the old talloc */
 typedef void TALLOC_CTX;
 

Modified: branches/SAMBA_3_0/source/lib/talloc/talloc.pc.in
===================================================================
--- branches/SAMBA_3_0/source/lib/talloc/talloc.pc.in	2007-04-19 09:08:30 UTC (rev 22365)
+++ branches/SAMBA_3_0/source/lib/talloc/talloc.pc.in	2007-04-19 09:08:53 UTC (rev 22366)
@@ -6,5 +6,6 @@
 Name: talloc 
 Description: A hierarchical pool based memory system with destructors
 Version: 4.0
-Libs: @LIBS@ -L${libdir} -ltalloc
-Cflags: -I${includedir} @CFLAGS@
+Libs: -L${libdir} -ltalloc
+Cflags: -I${includedir} 
+URL: http://talloc.samba.org/

Modified: branches/SAMBA_3_0/source/lib/talloc/testsuite.c
===================================================================
--- branches/SAMBA_3_0/source/lib/talloc/testsuite.c	2007-04-19 09:08:30 UTC (rev 22365)
+++ branches/SAMBA_3_0/source/lib/talloc/testsuite.c	2007-04-19 09:08:53 UTC (rev 22366)
@@ -1012,6 +1012,8 @@
 
 static bool test_autofree(void)
 {
+#if _SAMBA_BUILD_ < 4
+	/* autofree test would kill smbtorture */
 	void *p;
 	printf("test: autofree [\nTALLOC AUTOFREE CONTEXT\n]\n");
 
@@ -1022,13 +1024,17 @@
 	talloc_free(p);
 
 	printf("success: autofree\n");
+#endif
 	return true;
 }
 
-int main(void)
+struct torture_context;
+bool torture_local_talloc(struct torture_context *tctx)
 {
 	bool ret = true;
 
+	setlinebuf(stdout);
+
 	talloc_disable_null_tracking();
 	talloc_enable_null_tracking();
 
@@ -1055,7 +1061,15 @@
 	}
 	ret &= test_autofree();
 
+	return ret;
+}
+
+#if _SAMBA_BUILD_ < 4
+int main(void)
+{
+	bool ret = torture_local_talloc(NULL);
 	if (!ret)
 		return -1;
 	return 0;
 }
+#endif



More information about the samba-cvs mailing list