Init functions in winbind idmap modules
abartlet at samba.org
Tue Apr 1 17:39:36 MDT 2014
On Tue, 2014-04-01 at 16:05 -0700, Christof Schmitt wrote:
> On Tue, Apr 01, 2014 at 01:25:49PM -0700, Jeremy Allison wrote:
> > On Tue, Apr 01, 2014 at 11:39:39AM -0700, Christof Schmitt wrote:
> > > The init functions in the winbind idmap modules are not very consistent,
> > > some are called samba_init_module, others use different names:
> > >
> > > source3/winbindd/idmap_ad.c:NTSTATUS samba_init_module(void)
> > > source3/winbindd/idmap_autorid.c:NTSTATUS samba_init_module(void)
> > > source3/winbindd/idmap_ldap.c:NTSTATUS idmap_ldap_init(void)
> > > source3/winbindd/idmap_nss.c:NTSTATUS idmap_nss_init(void)
> > > source3/winbindd/idmap_passdb.c:NTSTATUS idmap_passdb_init(void)
> > > source3/winbindd/idmap_rfc2307.c:NTSTATUS idmap_rfc2307_init(void)
> > > source3/winbindd/idmap_rid.c:NTSTATUS samba_init_module(void)
> > >
> > > I also saw that there is some code in waf to create a define to
> > > samba_init_module, but i find that somewhat confusing.
> > >
> > > Should all modules use a similar init function name for consistency?
> > That would probably help. Send in a patch and I'll
> > review !
> Maybe this patch would be a start. It renames all init functions named
> samba_init_module to a name based on the module. The complexity with the
> define in waf is still there, but at least all modules are treated the
The waf complexity is there so allow modules to be builtin or as .so
files. They should always have a unique name, and be renamed by waf if
they are being built as .so files.
Authentication Developer, Samba Team http://samba.org
Samba Developer, Catalyst IT http://catalyst.net.nz/services/samba
More information about the samba-technical