From e96f8f1fe062a0ad3a8696c7f6ef8055ac9b57a6 Mon Sep 17 00:00:00 2001 From: David Shaw Date: Sun, 2 Jun 2002 22:19:39 +0000 Subject: [PATCH] * photoid.c (show_photos): Work properly when not called with a public key. --- g10/ChangeLog | 5 +++++ g10/photoid.c | 5 +++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/g10/ChangeLog b/g10/ChangeLog index 7923b8178..14cca8154 100644 --- a/g10/ChangeLog +++ b/g10/ChangeLog @@ -1,3 +1,8 @@ +2002-06-02 David Shaw + + * photoid.c (show_photos): Work properly when not called with a + public key. + 2002-05-31 David Shaw * sign.c (mk_notation_and_policy): Free unneeded buffer. diff --git a/g10/photoid.c b/g10/photoid.c index d696c761c..65a0243f1 100644 --- a/g10/photoid.c +++ b/g10/photoid.c @@ -220,12 +220,13 @@ void show_photos(const struct user_attribute *attrs, int i; struct expando_args args; u32 len; - u32 kid[2]; + u32 kid[2]={0,0}; memset(&args,0,sizeof(args)); args.pk=pk; - keyid_from_pk(pk,kid); + if(pk) + keyid_from_pk(pk,kid); for(i=0;i