winbindd causes sigsegv after the ads ticket is renewed
(i.e. ads->auth.expire > time(NULL)) because ads->schema
is filled with NULL and is NOT initialized in that case.
-- fumiyas

See also:
http://lists.samba.org/archive/samba-cvs/2007-January/073777.html

--- samba-3.0.24/source/sam/idmap_ad.c	2007-02-05 03:59:23.000000000 +0900
+++ samba-3.0.24.osstech/source/sam/idmap_ad.c	2007-03-03 01:11:26.459137895 +0900
@@ -170,14 +170,14 @@ static NTSTATUS ad_idmap_get_sid_from_id
 		case ID_USERID:
 			if (asprintf(&expr, "(&(|(sAMAccountType=%d)(sAMAccountType=%d)(sAMAccountType=%d))(%s=%d))",
 				ATYPE_NORMAL_ACCOUNT, ATYPE_WORKSTATION_TRUST, ATYPE_INTERDOMAIN_TRUST,
-				ads->schema.posix_uidnumber_attr, (int)unid.uid) == -1) {
+				attr_uidnumber, (int)unid.uid) == -1) {
 				return NT_STATUS_NO_MEMORY;
 			}
 			break;
 		case ID_GROUPID:
 			if (asprintf(&expr, "(&(|(sAMAccountType=%d)(sAMAccountType=%d))(%s=%d))",
 				ATYPE_SECURITY_GLOBAL_GROUP, ATYPE_SECURITY_LOCAL_GROUP,
-				ads->schema.posix_gidnumber_attr, (int)unid.gid) == -1) {
+				attr_gidnumber, (int)unid.gid) == -1) {
 				return NT_STATUS_NO_MEMORY;
 			}
 			break;
