diff options
author | Werner Koch <[email protected]> | 2021-04-01 08:31:52 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2021-04-01 08:31:52 +0000 |
commit | ff87f4e578f412332ae59fdab016f0a5304baaf9 (patch) | |
tree | 8bdc825e66936906031dcdc6bd0edf7f981c5d41 /scd/app-common.h | |
parent | scd:p15: New flag APP_LEARN_FLAG_REREAD. (diff) | |
download | gnupg-ff87f4e578f412332ae59fdab016f0a5304baaf9.tar.gz gnupg-ff87f4e578f412332ae59fdab016f0a5304baaf9.zip |
scd: New flag --reread for LEARN
* scd/command.c (cmd_learn): Add flag --reread.
* scd/app-common.h (struct app_ctx_s): New field need_reset.
* scd/app.c (write_learn_status_core): Set need_reset if we notice an
error after returning from a reread. Change all callers of card
functions to return GPG_ERR_CARD_RESET so that that app is not anymore
used.
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'scd/app-common.h')
-rw-r--r-- | scd/app-common.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/scd/app-common.h b/scd/app-common.h index c68fb8609..f194828a9 100644 --- a/scd/app-common.h +++ b/scd/app-common.h @@ -136,6 +136,7 @@ struct app_ctx_s { unsigned int force_chv1:1; /* True if the card does not cache CHV1. */ unsigned int did_chv2:1; unsigned int did_chv3:1; + unsigned int need_reset:1; /* Do't allow any functions but deinit. */ struct app_local_s *app_local; /* Local to the application. */ struct { void (*deinit) (app_t app); |