aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--g10/ChangeLog5
-rw-r--r--g10/keygen.c9
2 files changed, 13 insertions, 1 deletions
diff --git a/g10/ChangeLog b/g10/ChangeLog
index 2f1ba5bbc..7b0d67c01 100644
--- a/g10/ChangeLog
+++ b/g10/ChangeLog
@@ -1,3 +1,8 @@
+2005-08-04 David Shaw <[email protected]>
+
+ * keygen.c (start_tree): Need to use an actual packet type (which
+ we can then delete) to start the tree.
+
2005-08-04 Werner Koch <[email protected]>
* export.c (do_export_stream): Skip on-card keys when only subkeys
diff --git a/g10/keygen.c b/g10/keygen.c
index a657c13c9..4ff68941e 100644
--- a/g10/keygen.c
+++ b/g10/keygen.c
@@ -2667,7 +2667,14 @@ start_tree(KBNODE *tree)
PACKET *pkt;
pkt=xmalloc_clear(sizeof(*pkt));
- pkt->pkttype=PKT_NONE;
+
+ /* We're not acually using a user ID here - this is just an
+ arbitrary choice. We delete it anyway. */
+
+ pkt->pkttype=PKT_USER_ID;
+ pkt->pkt.user_id=xmalloc_clear(sizeof *pkt->pkt.user_id);
+ pkt->pkt.user_id->ref=1;
+
*tree=new_kbnode(pkt);
delete_kbnode(*tree);
}