aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--g10/ChangeLog7
-rw-r--r--g10/build-packet.c2
-rw-r--r--g10/import.c3
3 files changed, 11 insertions, 1 deletions
diff --git a/g10/ChangeLog b/g10/ChangeLog
index ee69d3555..2676d3215 100644
--- a/g10/ChangeLog
+++ b/g10/ChangeLog
@@ -1,3 +1,10 @@
+Tue Feb 15 08:48:13 CET 2000 Werner Koch <[email protected]>
+
+ * build-packet.c (build_packet): Fixed fixing of old comment packets.
+
+ * import.c (import_keys): Fixed importing from stdin when called with
+ nnames set to zero as it normally happens.
+
Mon Feb 14 14:30:20 CET 2000 Werner Koch <[email protected]>
* sig-check.c (check_key_signature2): Add new arg r_expired.
diff --git a/g10/build-packet.c b/g10/build-packet.c
index 3745d51c1..78c594db8 100644
--- a/g10/build-packet.c
+++ b/g10/build-packet.c
@@ -74,7 +74,7 @@ build_packet( IOBUF out, PACKET *pkt )
assert( pkt->pkt.generic );
switch( (pkttype = pkt->pkttype) ) {
- case PKT_OLD_COMMENT: pkt->pkttype = PKT_COMMENT; break;
+ case PKT_OLD_COMMENT: pkttype = pkt->pkttype = PKT_COMMENT; break;
case PKT_PLAINTEXT: new_ctb = pkt->pkt.plaintext->new_ctb; break;
case PKT_ENCRYPTED:
case PKT_ENCRYPTED_MDC: new_ctb = pkt->pkt.encrypted->new_ctb; break;
diff --git a/g10/import.c b/g10/import.c
index 88177a533..78a1cfc8a 100644
--- a/g10/import.c
+++ b/g10/import.c
@@ -115,6 +115,9 @@ import_keys( char **fnames, int nnames, int fast )
/* fixme: don't use static variables */
memset( &stats, 0, sizeof( stats ) );
+ if( !fnames && !nnames )
+ nnames = 1; /* Ohh what a ugly hack to jump into the loop */
+
for(i=0; i < nnames; i++ ) {
const char *fname = fnames? fnames[i] : NULL;
IOBUF inp = iobuf_open(fname);