Module Name: src Committed By: agc Date: Wed Dec 17 16:50:52 UTC 2014
Modified Files: src/crypto/external/bsd/netpgp/dist/src/netpgpkeys: netpgpkeys.c Log Message: Fix bug report from Jared - actually print the key when exporting To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 \ src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c diff -u src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c:1.25 src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c:1.26 --- src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c:1.25 Wed Feb 22 06:58:55 2012 +++ src/crypto/external/bsd/netpgp/dist/src/netpgpkeys/netpgpkeys.c Wed Dec 17 16:50:52 2014 @@ -196,6 +196,7 @@ static int netpgp_cmd(netpgp_t *netpgp, prog_t *p, char *f) { char *key; + char *s; switch (p->cmd) { case LIST_KEYS: @@ -211,8 +212,10 @@ netpgp_cmd(netpgp_t *netpgp, prog_t *p, key = netpgp_getvar(netpgp, "userid"); } if (key) { - printf("%s", key); - return 1; + if ((s = netpgp_export_key(netpgp, key)) != NULL) { + printf("%s", s); + return 1; + } } (void) fprintf(stderr, "key '%s' not found\n", f); return 0;