From: Marcus Brinkmann Date: Tue, 28 Sep 2004 23:15:39 +0000 (+0000) Subject: doc/ X-Git-Tag: gpgme-1-0-0~11 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=cc769c66edcceb87d0d27658ff620a936004f867;p=gpgme.git doc/ 2004-09-29 Marcus Brinkmann * gpgme.texi (Key Management): Change type of keylist_mode in gpgme_key_t to gpgme_keylist_mode_t. gpgme/ 2004-09-29 Marcus Brinkmann * gpgme.h (GPGME_IMPORT_NEW, GPGME_IMPORT_UID, GPGME_IMPORT_SIG, GPGME_IMPORT_SUBKEY, GPGME_IMPORT_SECRET, (GPGME_KEYLIST_MODE_LOCAL, GPGME_KEYLIST_MODERN_EXTERN, GPGME_KEYLIST_MODE_SIGS, GPGME_KEYLIST_MODE_VALIDATE): Change from enum to macros. (gpgme_keylist_mode_t): Define as unsigned int. (gpgme_key_t): Change type of keylist_mode to gpgme_keylist_mode_t. --- diff --git a/doc/ChangeLog b/doc/ChangeLog index c87e249..49f46c9 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,8 @@ +2004-09-29 Marcus Brinkmann + + * gpgme.texi (Key Management): Change type of keylist_mode in + gpgme_key_t to gpgme_keylist_mode_t. + 2004-09-28 Marcus Brinkmann * gpgme.texi (Passphrase Callback): Fix last change. diff --git a/doc/gpgme.texi b/doc/gpgme.texi index f63df52..5617a33 100644 --- a/doc/gpgme.texi +++ b/doc/gpgme.texi @@ -2351,7 +2351,7 @@ The @code{gpgme_key_t} type is a pointer to a key object. It has the following members: @table @code -@item unsigned int keylist_mode +@item gpgme_keylist_mode_t keylist_mode The keylist mode that was active when the key was retrieved. @item unsigned int revoked : 1 diff --git a/gpgme/ChangeLog b/gpgme/ChangeLog index 57177e8..1ffffd2 100644 --- a/gpgme/ChangeLog +++ b/gpgme/ChangeLog @@ -1,3 +1,14 @@ +2004-09-29 Marcus Brinkmann + + * gpgme.h (GPGME_IMPORT_NEW, GPGME_IMPORT_UID, GPGME_IMPORT_SIG, + GPGME_IMPORT_SUBKEY, GPGME_IMPORT_SECRET, + (GPGME_KEYLIST_MODE_LOCAL, GPGME_KEYLIST_MODERN_EXTERN, + GPGME_KEYLIST_MODE_SIGS, GPGME_KEYLIST_MODE_VALIDATE): Change from + enum to macros. + (gpgme_keylist_mode_t): Define as unsigned int. + (gpgme_key_t): Change type of keylist_mode to + gpgme_keylist_mode_t. + 2004-09-23 Marcus Brinkmann * data.c (_gpgme_data_outbound_handler): Close the file descriptor diff --git a/gpgme/gpgme.h b/gpgme/gpgme.h index dc1aa23..a95a6e8 100644 --- a/gpgme/gpgme.h +++ b/gpgme/gpgme.h @@ -306,14 +306,12 @@ gpgme_protocol_t; /* The available keylist mode flags. */ -typedef enum - { - GPGME_KEYLIST_MODE_LOCAL = 1, - GPGME_KEYLIST_MODE_EXTERN = 2, - GPGME_KEYLIST_MODE_SIGS = 4, - GPGME_KEYLIST_MODE_VALIDATE = 256 - } -gpgme_keylist_mode_t; +#define GPGME_KEYLIST_MODE_LOCAL 1 +#define GPGME_KEYLIST_MODE_EXTERN 2 +#define GPGME_KEYLIST_MODE_SIGS 4 +#define GPGME_KEYLIST_MODE_VALIDATE 256 + +typedef unsigned int gpgme_keylist_mode_t; /* The possible stati for the edit operation. */ @@ -653,10 +651,7 @@ struct _gpgme_key gpgme_user_id_t _last_uid; /* The keylist mode that was active when listing the key. */ - /* Implementation note: We are using unsigned int here, and not - gpgme_keylist_mode_t, as the latter is currently an enum of - unknown size. */ - unsigned int keylist_mode; + gpgme_keylist_mode_t keylist_mode; }; typedef struct _gpgme_key *gpgme_key_t; @@ -1229,23 +1224,22 @@ gpgme_error_t gpgme_op_verify (gpgme_ctx_t ctx, gpgme_data_t sig, /* Import. */ -enum - { - /* The key was new. */ - GPGME_IMPORT_NEW = 1, - /* The key contained new user IDs. */ - GPGME_IMPORT_UID = 2, +/* The key was new. */ +#define GPGME_IMPORT_NEW 1 + +/* The key contained new user IDs. */ +#define GPGME_IMPORT_UID 2 + +/* The key contained new signatures. */ +#define GPGME_IMPORT_SIG 4 - /* The key contained new signatures. */ - GPGME_IMPORT_SIG = 4, +/* The key contained new sub keys. */ +#define GPGME_IMPORT_SUBKEY 8 - /* The key contained new sub keys. */ - GPGME_IMPORT_SUBKEY = 8, +/* The key contained a secret key. */ +#define GPGME_IMPORT_SECRET 16 - /* The key contained a secret key. */ - GPGME_IMPORT_SECRET = 16 - }; struct _gpgme_import_status {