Home GnuPG
Diffusion GnuPG 9639af5f16a7

scd: Simplify saving application context.
9639af5f16a7Unpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

scd: Simplify saving application context.

* scd/app.c (lock_table): Remove LAST_APP field.
(lock_reader, app_dump_state, application_notify_card_reset)
(release_application): Follow the change.
(check_conflict): New.
(check_application_conflict): Lock the slot and call check_conflict.
(select_application): Call check_conflict and not use LAST_APP.

We don't need LAST_APP field but just keep the application context by
APP field. Since we have a reference counter, it is possible if we
can deallocate or not.

Details

Provenance
gniibeAuthored on Dec 4 2015, 6:13 AM
Parents
rGf747adfa2155: scd: More fix for Curve25519 prefix handling.
Branches
Unknown
Tags
Unknown

Event Timeline

NIIBE Yutaka <gniibe@fsij.org> committed rG9639af5f16a7: scd: Simplify saving application context. (authored by NIIBE Yutaka <gniibe@fsij.org>).Dec 4 2015, 6:13 AM