Remove the disconnect action from internal reader api

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2861 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
martin 2006-03-01 09:45:09 +00:00
parent b93d6b1562
commit e1ef4ec241
5 changed files with 7 additions and 10 deletions

View File

@ -220,7 +220,7 @@ int sc_connect_card(sc_reader_t *reader, int slot_id, sc_card_t **card_out)
SC_FUNC_RETURN(ctx, 1, 0);
err:
if (connected)
reader->ops->disconnect(reader, slot, 0);
reader->ops->disconnect(reader, slot);
if (card != NULL)
sc_card_free(card);
SC_FUNC_RETURN(ctx, 1, r);
@ -240,7 +240,7 @@ int sc_disconnect_card(sc_card_t *card, int action)
sc_strerror(r));
}
if (card->reader->ops->disconnect) {
int r = card->reader->ops->disconnect(card->reader, card->slot, action);
int r = card->reader->ops->disconnect(card->reader, card->slot);
if (r)
sc_error(card->ctx, "disconnect() failed: %s\n",
sc_strerror(r));

View File

@ -378,8 +378,7 @@ struct sc_reader_operations {
int (*detect_card_presence)(struct sc_reader *reader,
struct sc_slot_info *slot);
int (*connect)(struct sc_reader *reader, struct sc_slot_info *slot);
int (*disconnect)(struct sc_reader *reader, struct sc_slot_info *slot,
int action);
int (*disconnect)(struct sc_reader *reader, struct sc_slot_info *slot);
int (*transmit)(struct sc_reader *reader, struct sc_slot_info *slot,
sc_apdu_t *apdu);
int (*lock)(struct sc_reader *reader, struct sc_slot_info *slot);

View File

@ -420,8 +420,7 @@ static int ctapi_connect(sc_reader_t *reader, sc_slot_info_t *slot)
return 0;
}
static int ctapi_disconnect(sc_reader_t *reader, sc_slot_info_t *slot,
int action)
static int ctapi_disconnect(sc_reader_t *reader, sc_slot_info_t *slot)
{
return 0;
}

View File

@ -41,7 +41,7 @@ static int openct_reader_detect_card_presence(sc_reader_t *reader,
static int openct_reader_connect(sc_reader_t *reader,
sc_slot_info_t *slot);
static int openct_reader_disconnect(sc_reader_t *reader,
sc_slot_info_t *slot, int action);
sc_slot_info_t *slot);
static int openct_reader_transmit(sc_reader_t *reader,
sc_slot_info_t *slot, sc_apdu_t *apdu);
static int openct_reader_perform_verify(sc_reader_t *reader,
@ -273,7 +273,7 @@ openct_reader_reconnect(sc_reader_t *reader,
int
openct_reader_disconnect(sc_reader_t *reader,
sc_slot_info_t *slot, int action)
sc_slot_info_t *slot)
{
struct driver_data *data = (struct driver_data *) reader->drv_data;

View File

@ -554,8 +554,7 @@ static int pcsc_connect(sc_reader_t *reader, sc_slot_info_t *slot)
return SC_SUCCESS;
}
static int pcsc_disconnect(sc_reader_t *reader, sc_slot_info_t *slot,
int action)
static int pcsc_disconnect(sc_reader_t * reader, sc_slot_info_t * slot)
{
struct pcsc_slot_data *pslot = GET_SLOT_DATA(slot);
struct pcsc_private_data *priv = GET_PRIV_DATA(reader);