[Fedora-directory-commits] ldapserver/ldap/servers/slapd/back-ldbm import-threads.c, 1.12, 1.13

Noriko Hosoi (nhosoi) fedora-directory-commits at redhat.com
Mon Jun 11 17:22:40 UTC 2007


Author: nhosoi

Update of /cvs/dirsec/ldapserver/ldap/servers/slapd/back-ldbm
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11857/ldap/servers/slapd/back-ldbm

Modified Files:
	import-threads.c 
Log Message:
Resolves: #243488
Summary: Use mozldap6 ldif_parse_line API 
Changes:
1) Removed ldif.h from the DS tree.
2) Eliminated the 5-th arg of ldif_parse_line (errmsg) and the errmsg related
code. 



Index: import-threads.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/back-ldbm/import-threads.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- import-threads.c	10 Nov 2006 23:45:39 -0000	1.12
+++ import-threads.c	11 Jun 2007 17:22:38 -0000	1.13
@@ -283,21 +283,16 @@
     offset = s - str;
     mystr = ms = slapi_ch_strdup(str);
     while ( (s = ldif_getline( &ms )) != NULL ) {
-        char *errmsg = NULL;
-	if ( (retmalloc = ldif_parse_line( s, &type, &valuecharptr, &valuelen, &errmsg )) >= 0 ) {
+	if ( (retmalloc = ldif_parse_line( s, &type, &valuecharptr, &valuelen )) >= 0 ) {
 	    if (!strcasecmp(type, "version")) {
 		my_version = atoi(valuecharptr);
 		*(str + offset) = '#';
 		/* the memory below was not allocated by the slapi_ch_ functions */
-		if (errmsg) PR_smprintf_free(errmsg);
 		if (retmalloc) slapi_ch_free((void **) &valuecharptr);
 		break;
 	    } 
-	} else if ( errmsg != NULL ) {
-	    LDAPDebug( LDAP_DEBUG_PARSE, "%s", errmsg, 0, 0 );
 	}
 	/* the memory below was not allocated by the slapi_ch_ functions */
-	if (errmsg) slapi_ch_free((void **) &errmsg);
 	if (retmalloc) slapi_ch_free((void **) &valuecharptr);
     }
 




More information about the Fedora-directory-commits mailing list