pkcs15-init tool: fix for pin auth_type comparison

partial merge of pull request
https://github.com/OpenSC/OpenSC/pull/8

Thanks to 'joelhockey'.
This commit is contained in:
Viktor Tarasov 2012-02-22 09:42:30 +01:00
parent e6c501f3de
commit 2b63213e0a
1 changed files with 1 additions and 1 deletions

View File

@ -2724,7 +2724,7 @@ int get_pin(sc_ui_hints_t *hints, char **out)
int flags = hints->flags;
pin_info = hints->info.pin;
if (pin_info && pin_info->auth_type == SC_PKCS15_PIN_AUTH_TYPE_PIN)
if (pin_info && pin_info->auth_type != SC_PKCS15_PIN_AUTH_TYPE_PIN)
return SC_ERROR_NOT_SUPPORTED;
if (!(label = hints->obj_label)) {