1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00

scd: Simplify inclusion of app-common.h.

* scd/scdaemon.h: Include app-common.h.  Remove inclusion of that
header from all other files.
(card_t, app_t): Move typedef to ...
* scd/app-common.h: here.  Use them in the defs.
--

In another patch we will need apptype_t in the ctrl object and thus we
need to reorganize things a bit now.  Given that most files need
app-common anyway it makes sense to always include it.

Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
Werner Koch 2019-06-21 10:23:35 +02:00
parent 4256e9f0f1
commit 43dcf93407
No known key found for this signature in database
GPG key ID: E3FDFF218E45B72B
13 changed files with 10 additions and 16 deletions

View file

@ -70,13 +70,18 @@ typedef enum
} apptype_t;
/* Formeard declararion. */
/* Forward declarations. */
struct card_ctx_s;
struct app_ctx_s;
struct app_local_s; /* Defined by all app-*.c. */
typedef struct card_ctx_s *card_t;
typedef struct app_ctx_s *app_t;
/* The object describing a card. */
struct card_ctx_s {
struct card_ctx_s *next;
card_t next;
npth_mutex_t lock;
@ -114,7 +119,7 @@ struct card_ctx_s {
* several applications and it is usuallay required to explicity
* switch between applications. */
struct app_ctx_s {
struct app_ctx_s *next;
app_t next;
card_t card; /* Link back to the card. */