mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-03-07 14:18:15 +08:00
Fix dirsep chars before opening file
This commit is contained in:
parent
3e05442795
commit
6ffbb9b04d
@ -57,6 +57,14 @@ ldif_open_url(
|
|||||||
}
|
}
|
||||||
|
|
||||||
p = ber_strdup( urlstr );
|
p = ber_strdup( urlstr );
|
||||||
|
|
||||||
|
/* But we should convert to LDAP_DIRSEP before use */
|
||||||
|
if ( LDAP_DIRSEP[0] != '/' ) {
|
||||||
|
char *s = p;
|
||||||
|
while (( s = strchr( s, '/' )))
|
||||||
|
*s++ = LDAP_DIRSEP[0];
|
||||||
|
}
|
||||||
|
|
||||||
ldap_pvt_hex_unescape( p );
|
ldap_pvt_hex_unescape( p );
|
||||||
|
|
||||||
url = fopen( p, "rb" );
|
url = fopen( p, "rb" );
|
||||||
|
Loading…
Reference in New Issue
Block a user