Using gcc3 on Solaris 10, I get a warning about a type mismatch Compiling nsswitch/nss_info_template.c nsswitch/nss_info_template.c:75: warning: initialization from incompatible pointer type This is the .get_nss_info = nss_template_get_info line below: static struct nss_info_methods nss_template_methods = { .init = nss_template_init, .get_nss_info = nss_template_get_info, .close_fn = nss_template_close };
It's define in nss_info.hline 66 as struct nss_info_methods { NTSTATUS (*init)( struct nss_domain_entry *e ); NTSTATUS (*get_nss_info)( struct nss_domain_entry *e, const DOM_SID *sid, TALLOC_CTX *ctx, ADS_STRUCT *ads, LDAPMessage *msg, char **homedir, char **shell, char **gecos, gid_t *p_gid); NTSTATUS (*close_fn)( void ); }; while the thing beingassigned is declared static NTSTATUS nss_template_get_info( struct nss_domain_entry *e, const DOM_SID *sid, TALLOC_CTX *ctx, ADS_STRUCT *ads, LDAPMessage *msg, char **homedir, char **shell, char **gecos, uint32 *gid ) These differ in the gid field, which is a gid_t * in the recipient of the assignment and a a uint32 * in the function bing assigned. --dave (nitpicking) c-b
this doesn't apply for recent samba versions any more