[SCM] Samba Shared Repository - branch master updated - release-4-0-0alpha7-389-g752cf03

Stefan Metzmacher metze at samba.org
Mon Mar 16 10:15:23 GMT 2009


The branch, master has been updated
       via  752cf03bf7854a4b32b0e1fedc1cb4ecd4474765 (commit)
       via  6d4a13241a096d30d37d69a8f7b888a395716316 (commit)
       via  a3998832dbdbeb9ba5f3576a242bd48a5a3b3b60 (commit)
       via  a73bd05eec608d29888286542e9c882039b02857 (commit)
       via  d0b9cc62f99a1feca68c473f3cd1e93e50ab2eab (commit)
       via  099d6f05cdb0800114d026786920a17ef649699f (commit)
      from  586a4da5dd30c371a33956db406bbb1dc08534b2 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 752cf03bf7854a4b32b0e1fedc1cb4ecd4474765
Author: Stefan Metzmacher <metze at samba.org>
Date:   Mon Mar 16 10:19:09 2009 +0100

    talloc: change version to 1.3.0
    
    metze

commit 6d4a13241a096d30d37d69a8f7b888a395716316
Author: Stefan Metzmacher <metze at samba.org>
Date:   Mon Mar 16 10:16:40 2009 +0100

    talloc: add useful talloc_array_length() macro
    
    metze

commit a3998832dbdbeb9ba5f3576a242bd48a5a3b3b60
Author: Stefan Metzmacher <metze at samba.org>
Date:   Mon Mar 16 10:13:58 2009 +0100

    talloc: add TALLOC_ZERO()
    
    metze

commit a73bd05eec608d29888286542e9c882039b02857
Author: Stefan Metzmacher <metze at samba.org>
Date:   Mon Mar 16 10:13:34 2009 +0100

    s3: only define TALLOC_ZERO if needed
    
    metze

commit d0b9cc62f99a1feca68c473f3cd1e93e50ab2eab
Author: Stefan Metzmacher <metze at samba.org>
Date:   Mon Mar 16 10:13:08 2009 +0100

    nsswitch: only define TALLOC_ZERO if needed
    
    metze

commit 099d6f05cdb0800114d026786920a17ef649699f
Author: Stefan Metzmacher <metze at samba.org>
Date:   Fri Mar 13 10:20:29 2009 +0100

    lib/replace: use AC_TRY_LINK() to verify that getifaddrs() and freeifaddrs() are available
    
    metze

-----------------------------------------------------------------------

Summary of changes:
 lib/replace/libreplace_network.m4 |    2 +-
 lib/talloc/configure.ac           |    2 +-
 lib/talloc/talloc.h               |    3 +++
 nsswitch/pam_winbind.h            |    2 ++
 source3/include/smb_macros.h      |    2 ++
 source3/libaddns/dns.h            |    2 ++
 6 files changed, 11 insertions(+), 2 deletions(-)


Changeset truncated at 500 lines:

diff --git a/lib/replace/libreplace_network.m4 b/lib/replace/libreplace_network.m4
index 1dc1c44..9223d94 100644
--- a/lib/replace/libreplace_network.m4
+++ b/lib/replace/libreplace_network.m4
@@ -242,7 +242,7 @@ AC_CHECK_MEMBERS([struct sockaddr.sa_len],
 
 dnl test for getifaddrs and freeifaddrs
 AC_CACHE_CHECK([for getifaddrs and freeifaddrs],libreplace_cv_HAVE_GETIFADDRS,[
-AC_TRY_COMPILE([
+AC_TRY_LINK([
 #include <sys/types.h>
 #if STDC_HEADERS
 #include <stdlib.h>
diff --git a/lib/talloc/configure.ac b/lib/talloc/configure.ac
index 39cea39..00e8242 100644
--- a/lib/talloc/configure.ac
+++ b/lib/talloc/configure.ac
@@ -1,5 +1,5 @@
 AC_PREREQ(2.50)
-AC_INIT(talloc, 1.2.1)
+AC_INIT(talloc, 1.3.0)
 AC_CONFIG_SRCDIR([talloc.c])
 AC_SUBST(datarootdir)
 AC_CONFIG_HEADER(config.h)
diff --git a/lib/talloc/talloc.h b/lib/talloc/talloc.h
index b623934..5c8d5c5 100644
--- a/lib/talloc/talloc.h
+++ b/lib/talloc/talloc.h
@@ -94,6 +94,7 @@ typedef void TALLOC_CTX;
 #define talloc_array(ctx, type, count) (type *)_talloc_array(ctx, sizeof(type), count, #type)
 #define talloc_array_size(ctx, size, count) _talloc_array(ctx, size, count, __location__)
 #define talloc_array_ptrtype(ctx, ptr, count) (_TALLOC_TYPEOF(ptr))talloc_array_size(ctx, sizeof(*(ptr)), count)
+#define talloc_array_length(ctx) ((ctx) ? talloc_get_size(ctx)/sizeof(*ctx) : 0)
 
 #define talloc_realloc(ctx, p, type, count) (type *)_talloc_realloc_array(ctx, p, sizeof(type), count, #type)
 #define talloc_realloc_size(ctx, ptr, size) _talloc_realloc(ctx, ptr, size, __location__)
@@ -115,6 +116,8 @@ typedef void TALLOC_CTX;
 #define talloc_append_string(c, s, a) (s?talloc_strdup_append(s,a):talloc_strdup(c, a))
 #endif
 
+#define TALLOC_FREE(ctx) do { talloc_free(ctx); ctx=NULL; } while(0)
+
 /* The following definitions come from talloc.c  */
 void *_talloc(const void *context, size_t size);
 void *talloc_pool(const void *context, size_t size);
diff --git a/nsswitch/pam_winbind.h b/nsswitch/pam_winbind.h
index 0395a1f..25d673e 100644
--- a/nsswitch/pam_winbind.h
+++ b/nsswitch/pam_winbind.h
@@ -171,6 +171,8 @@ struct pwb_context {
 	uint32_t ctrl;
 };
 
+#ifndef TALLOC_FREE
 #define TALLOC_FREE(ctx) do { talloc_free(ctx); ctx=NULL; } while(0)
+#endif
 #define TALLOC_ZERO_P(ctx, type) (type *)_talloc_zero(ctx, sizeof(type), #type)
 #define TALLOC_P(ctx, type) (type *)talloc_named_const(ctx, sizeof(type), #type)
diff --git a/source3/include/smb_macros.h b/source3/include/smb_macros.h
index fd1bba1..22cfaaf 100644
--- a/source3/include/smb_macros.h
+++ b/source3/include/smb_macros.h
@@ -256,7 +256,9 @@ NULL returns on zero request. JRA.
 #define TALLOC_REALLOC(ctx, ptr, count) _talloc_realloc(ctx, ptr, count, __location__)
 #define TALLOC_REALLOC_ARRAY(ctx, ptr, type, count) (type *)_talloc_realloc_array(ctx, ptr, sizeof(type), count, #type)
 #define talloc_destroy(ctx) talloc_free(ctx)
+#ifndef TALLOC_FREE
 #define TALLOC_FREE(ctx) do { talloc_free(ctx); ctx=NULL; } while(0)
+#endif
 
 /* only define PARANOID_MALLOC_CHECKER with --enable-developer */
 
diff --git a/source3/libaddns/dns.h b/source3/libaddns/dns.h
index 57a9b6a..a04a13b 100644
--- a/source3/libaddns/dns.h
+++ b/source3/libaddns/dns.h
@@ -133,7 +133,9 @@ void *talloc_zeronull(const void *context, size_t size, const char *name);
 #define TALLOC_REALLOC(ctx, ptr, count) _talloc_realloc(ctx, ptr, count, __location__)
 #define TALLOC_REALLOC_ARRAY(ctx, ptr, type, count) (type *)_talloc_realloc_array(ctx, ptr, sizeof(type), count, #type)
 #define talloc_destroy(ctx) talloc_free(ctx)
+#ifndef TALLOC_FREE
 #define TALLOC_FREE(ctx) do { talloc_free(ctx); ctx=NULL; } while(0)
+#endif
 
 /*******************************************************************
    Type definitions for int16, int32, uint16 and uint32.  Needed


-- 
Samba Shared Repository


More information about the samba-cvs mailing list