--list-secret-keys bug in CVS tree, and a warning fix

Remi Guyomarch rguyom at mail.dotcom.fr
Sat Feb 27 13:45:11 CET 1999


Hi all,

In the CVS code, "--list-secret-keys <some-user-id>" prints :

gpg: Oops; key lost!
node 0x80ac920 00/00 type=secret-key
node 0x80ac980 00/00 type=user-id  "Remi Guyomarch (DSS) <rguyom at mail.dotcom.fr>"
node 0x80aca70 00/00 type=signature  keyid=85BD8B1B
node 0x80acad0 00/00 type=user-id  "Remi Guyomarch (DSS) <remi at distributed.net>"
node 0x80acbc0 00/00 type=signature  keyid=85BD8B1B
node 0x80ad018 00/00 type=secret-subkey
node 0x80ad0e0 00/00 type=signature  keyid=85BD8B1B

Here's the patch against keylist 1.17 :
===================================================================
RCS file: /home/koch/cvs/gnupg/g10/keylist.c,v
retrieving revision 1.17
diff -u -r1.17 keylist.c
--- keylist.c   1999/02/24 10:12:25     1.17
+++ keylist.c   1999/02/27 12:37:49
@@ -132,7 +132,7 @@
        }
        do {
            merge_keys_and_selfsig( keyblock );
-           list_keyblock( keyblock, 0 );
+           list_keyblock( keyblock, 1 );
            release_kbnode( keyblock );
        } while( !get_seckey_next( ctx, NULL, &keyblock ) );
        get_seckey_end( ctx );


Another litle patch to fix a warning with egcs :
===================================================================
RCS file: /home/koch/cvs/gnupg/g10/keyedit.c,v
retrieving revision 1.36
diff -u -r1.36 keyedit.c
--- keyedit.c   1999/02/16 13:16:26     1.36
+++ keyedit.c   1999/02/27 12:37:49
@@ -1337,11 +1337,12 @@
     /* and toggle the new index */
     for( i=0, node = keyblock; node; node = node->next ) {
        if( node->pkt->pkttype == PKT_USER_ID ) {
-           if( ++i == idx )
+           if( ++i == idx ) {
                if( (node->flag & NODFLG_SELUID) )
                    node->flag &= ~NODFLG_SELUID;
                else
                    node->flag |= NODFLG_SELUID;
+           }
        }
     }
 
@@ -1384,11 +1385,12 @@
     for( i=0, node = keyblock; node; node = node->next ) {
        if( node->pkt->pkttype == PKT_PUBLIC_SUBKEY
            || node->pkt->pkttype == PKT_SECRET_SUBKEY ) {
-           if( ++i == idx )
+           if( ++i == idx ) {
                if( (node->flag & NODFLG_SELKEY) )
                    node->flag &= ~NODFLG_SELKEY;
                else
                    node->flag |= NODFLG_SELKEY;
+           }
        }
     }
 

-- 
Rémi        <rguyom at mail.dotcom.fr> | Don't waste your computer's time :
    PGP-encrypt anything important: | http://www.distributed.net/
   www.gnupg.org - KeyID:0x85BD8B1B | http://www.distributed.net/cores/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 240 bytes
Desc: not available
Url : /pipermail/attachments/19990227/67dcd382/attachment.bin


More information about the Gnupg-devel mailing list