paranoid malloc checker forced on - samba3 build broken atm

Guenter Kukkukk lists at kukkukk.com
Thu May 5 23:33:11 GMT 2005


Hi all,

as of svn version 6616, samba3 build is broken here on SuSE 9.1, when
using all SuSE configure options.

Some semantics in talloc.h have changed recently, so at least the following
2 files must be changed:

passdb/pdb_mysql.c
passdb/pdb_xml.c

In passdb/pdb_mysql.c ->   static NTSTATUS mysqlsam_init()
....
-  data = talloc(pdb_context->mem_ctx, sizeof(struct pdb_mysql_data));
+ data = talloc(pdb_context->mem_ctx, struct pdb_mysql_data);

In passdb/pdb_xml.c ->   static NTSTATUS xmlsam_init()
....
 - data = talloc(pdb_context->mem_ctx, sizeof(pdb_xml));
+ data = talloc(pdb_context->mem_ctx, pdb_xml);

In addition, to get the build done, i had to comment out Jeremys latest addition to
include/smb_macros.h:
- #if defined(DEVELOPER) && !defined(SMBMOUNT_MALLOC)
- #  define PARANOID_MALLOC_CHECKER 1
- #endif

Cause DEVELOPER is defined here during build, i always get
PARANOID_MALLOC_CHECKER defined.
This breaks client/smbmnt.c (and others) _even_ when strdup() is replaced
with SMB_STRDUP(). In that case smb_xstrdup() from lib/util.c is used.
But that object file is currently not included during the link step.

Cheers, Guenter




More information about the samba-technical mailing list