diff --git a/src/libopensc/card-oberthur.c b/src/libopensc/card-oberthur.c index 3798abf8..cbb5d37c 100644 --- a/src/libopensc/card-oberthur.c +++ b/src/libopensc/card-oberthur.c @@ -1886,7 +1886,6 @@ static int auth_pin_reset(struct sc_card *card, unsigned int type, struct sc_pin_cmd_data *data, int *tries_left) { - struct sc_card_driver *iso_drv = sc_get_iso7816_driver(); int rv; SC_FUNC_CALLED(card->ctx, 1); @@ -1902,10 +1901,7 @@ auth_pin_reset(struct sc_card *card, unsigned int type, static int auth_pin_cmd(struct sc_card *card, struct sc_pin_cmd_data *data, int *tries_left) { - struct sc_card_driver *iso_drv = sc_get_iso7816_driver(); - struct auth_private_data *prv_data = (struct auth_private_data *) card->drv_data; - struct sc_apdu apdu; - int rv, _tries_left = 0; + int rv; SC_FUNC_CALLED(card->ctx, 1); if (data->pin_type != SC_AC_CHV) diff --git a/src/libopensc/pkcs15-pin.c b/src/libopensc/pkcs15-pin.c index c5cc03bc..0c7a4ed4 100644 --- a/src/libopensc/pkcs15-pin.c +++ b/src/libopensc/pkcs15-pin.c @@ -511,7 +511,6 @@ int sc_pkcs15_pincache_revalidate(struct sc_pkcs15_card *p15card, sc_pkcs15_obje { struct sc_context *ctx = p15card->card->ctx; sc_pkcs15_object_t *pin_obj; - sc_pkcs15_pin_info_t *pin_info; int r; SC_FUNC_CALLED(ctx, 2); @@ -542,7 +541,8 @@ int sc_pkcs15_pincache_revalidate(struct sc_pkcs15_card *p15card, sc_pkcs15_obje * before or after (successeful ?) PIN verifying ? */ pin_obj->usage_counter++; - r = sc_pkcs15_verify_pin(p15card, pin_info, pin_obj->content.value, pin_obj->content.len); + r = sc_pkcs15_verify_pin(p15card, (struct sc_pkcs15_pin_info *)pin_obj->data, + pin_obj->content.value, pin_obj->content.len); if (r != SC_SUCCESS) { sc_debug(ctx, "Verify PIN error %i", r); return SC_ERROR_SECURITY_STATUS_NOT_SATISFIED; diff --git a/src/libopensc/pkcs15.c b/src/libopensc/pkcs15.c index 5e3c93e6..676ad02f 100644 --- a/src/libopensc/pkcs15.c +++ b/src/libopensc/pkcs15.c @@ -1164,7 +1164,6 @@ int sc_pkcs15_find_pin_by_type_and_reference(struct sc_pkcs15_card *p15card, struct sc_pkcs15_object **out) { struct sc_context *ctx = p15card->card->ctx; - struct sc_pkcs15_pin_info pinfo; struct sc_pkcs15_object *auth_objs[0x10]; int r, nn_objs, ii;