mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-02-11 13:50:39 +08:00
ber_get_enum() needs int*, not enum*. An enum can have wrong size.
(Enum _members_ have type int, but the enum's _type_ can be compatible with some other char/integer type which can represent its members.)
This commit is contained in:
parent
570126dc25
commit
bdbda6a231
@ -134,7 +134,7 @@ ldap_parse_passwordpolicy_control(
|
|||||||
ber_tag_t tag;
|
ber_tag_t tag;
|
||||||
ber_len_t berLen;
|
ber_len_t berLen;
|
||||||
char *last;
|
char *last;
|
||||||
LDAPPasswordPolicyError err = PP_noError;
|
int err = PP_noError;
|
||||||
|
|
||||||
assert( ld != NULL );
|
assert( ld != NULL );
|
||||||
assert( LDAP_VALID( ld ) );
|
assert( LDAP_VALID( ld ) );
|
||||||
@ -172,7 +172,7 @@ ldap_parse_passwordpolicy_control(
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
case PPOLICY_ERROR:
|
case PPOLICY_ERROR:
|
||||||
if (ber_get_enum( ber, (int *)&err ) == LBER_DEFAULT) goto exit;
|
if (ber_get_enum( ber, &err ) == LBER_DEFAULT) goto exit;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
goto exit;
|
goto exit;
|
||||||
|
Loading…
Reference in New Issue
Block a user