/* $OpenLDAP$ */
/* This work is part of OpenLDAP Software <http://www.openldap.org/>.
*
- * Copyright 1998-2007 The OpenLDAP Foundation.
+ * Copyright 1998-2008 The OpenLDAP Foundation.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
}
#endif
+ if ( *oc == NULL ) {
+ return 0;
+ }
+
*oc = LDAP_STAILQ_NEXT(*oc,soc_next);
return (*oc != NULL);
}
int
-register_oc( char *def, ObjectClass **soc, int dupok )
+register_oc( const char *def, ObjectClass **soc, int dupok )
{
LDAPObjectClass *oc;
int code;