[Pkg-gnupg-commit] [gnupg2] 89/124: gpg: Export ring trust packets in backup mode.

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed Apr 5 15:55:36 UTC 2017


This is an automated email from the git hooks/post-receive script.

dkg pushed a commit to branch experimental
in repository gnupg2.

commit f5b565a5b8de3f2a3d98bc1a655e18333aee223b
Author: Werner Koch <wk at gnupg.org>
Date:   Wed Mar 29 08:44:52 2017 +0200

    gpg: Export ring trust packets in backup mode.
    
    * g10/export.c (write_keyblock_to_output): Export ring trust packets.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>
---
 g10/export.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/g10/export.c b/g10/export.c
index a7aecd6..5b0c81d 100644
--- a/g10/export.c
+++ b/g10/export.c
@@ -1282,8 +1282,11 @@ write_keyblock_to_output (kbnode_t keyblock, int with_armor,
 
   for (node = keyblock; node; node = node->next)
     {
-      if (is_deleted_kbnode (node) || node->pkt->pkttype == PKT_RING_TRUST)
+      if (is_deleted_kbnode (node))
         continue;
+      if (node->pkt->pkttype == PKT_RING_TRUST && !(options & EXPORT_BACKUP))
+        continue;
+
       if (!pk && (node->pkt->pkttype == PKT_PUBLIC_KEY
                   || node->pkt->pkttype == PKT_SECRET_KEY))
         pk = node->pkt->pkt.public_key;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg2.git



More information about the Pkg-gnupg-commit mailing list