mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
g10: Move more flags into the flag bitfield.
* g10/packet.h (PKT_user_id): Move 'is_primary', 'is_revoked', and 'is_expired' into the flags bitfield, and drop the prefix. * g10/call-dirmngr.c: Adapt accordingly. * g10/export.c: Likewise. * g10/getkey.c: Likewise. * g10/import.c: Likewise. * g10/kbnode.c: Likewise. * g10/keyedit.c: Likewise. * g10/keylist.c: Likewise. * g10/keyserver.c: Likewise. * g10/mainproc.c: Likewise. * g10/pkclist.c: Likewise. * g10/pubkey-enc.c: Likewise. * g10/tofu.c: Likewise. * g10/trust.c: Likewise. * g10/trustdb.c: Likewise. -- This patch has been created by applying the following semantic patch: @@ expression E; @@ -E->is_expired +E->flags.expired @@ expression E; @@ -E->is_primary +E->flags.primary @@ expression E; @@ -E->is_revoked +E->flags.revoked Signed-off-by: Justus Winter <justus@g10code.com>
This commit is contained in:
parent
8f02864223
commit
2649fdfff5
15 changed files with 90 additions and 92 deletions
|
@ -1960,11 +1960,11 @@ check_sig_and_print (CTX c, kbnode_t node)
|
|||
continue;
|
||||
if (!un->pkt->pkt.user_id->created)
|
||||
continue;
|
||||
if (un->pkt->pkt.user_id->is_revoked)
|
||||
if (un->pkt->pkt.user_id->flags.revoked)
|
||||
continue;
|
||||
if (un->pkt->pkt.user_id->is_expired)
|
||||
if (un->pkt->pkt.user_id->flags.expired)
|
||||
continue;
|
||||
if (!un->pkt->pkt.user_id->is_primary)
|
||||
if (!un->pkt->pkt.user_id->flags.primary)
|
||||
continue;
|
||||
/* We want the textual primary user ID here */
|
||||
if (un->pkt->pkt.user_id->attrib_data)
|
||||
|
@ -2041,12 +2041,12 @@ check_sig_and_print (CTX c, kbnode_t node)
|
|||
{
|
||||
if (un->pkt->pkttype != PKT_USER_ID)
|
||||
continue;
|
||||
if ((un->pkt->pkt.user_id->is_revoked
|
||||
|| un->pkt->pkt.user_id->is_expired)
|
||||
if ((un->pkt->pkt.user_id->flags.revoked
|
||||
|| un->pkt->pkt.user_id->flags.expired)
|
||||
&& !(opt.verify_options & VERIFY_SHOW_UNUSABLE_UIDS))
|
||||
continue;
|
||||
/* Skip textual primary user ids which we printed above. */
|
||||
if (un->pkt->pkt.user_id->is_primary
|
||||
if (un->pkt->pkt.user_id->flags.primary
|
||||
&& !un->pkt->pkt.user_id->attrib_data )
|
||||
continue;
|
||||
|
||||
|
@ -2071,9 +2071,9 @@ check_sig_and_print (CTX c, kbnode_t node)
|
|||
{
|
||||
const char *valid;
|
||||
|
||||
if (un->pkt->pkt.user_id->is_revoked)
|
||||
if (un->pkt->pkt.user_id->flags.revoked)
|
||||
valid = _("revoked");
|
||||
else if (un->pkt->pkt.user_id->is_expired)
|
||||
else if (un->pkt->pkt.user_id->flags.expired)
|
||||
valid = _("expired");
|
||||
else
|
||||
/* Since this is just informational, don't
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue