diff options
Diffstat (limited to 'g10/photoid.c')
-rw-r--r-- | g10/photoid.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/g10/photoid.c b/g10/photoid.c index 37156f2..517fa21 100644 --- a/g10/photoid.c +++ b/g10/photoid.c @@ -21,7 +21,10 @@ #include <errno.h> #include <stdio.h> #include <string.h> -#ifdef _WIN32 +#ifdef _WIN32 +# ifdef HAVE_WINSOCK2_H +# include <winsock2.h> +# endif # include <windows.h> # ifndef VER_PLATFORM_WIN32_WINDOWS # define VER_PLATFORM_WIN32_WINDOWS 1 @@ -121,7 +124,7 @@ generate_photo_id(PKT_public_key *pk,const char *photo_name) continue; } - + len=iobuf_get_filelength(file, &overflow); if(len>6144 || overflow) { @@ -294,11 +297,12 @@ show_photos(const struct user_attribute *attrs, u32 len; u32 kid[2]={0,0}; - memset(&args,0,sizeof(args)); - args.pk=pk; - args.sk=sk; - args.validity_info=get_validity_info(pk,uid); - args.validity_string=get_validity_string(pk,uid); + memset (&args, 0, sizeof(args)); + args.pk = pk; + args.validity_info = get_validity_info (pk, uid); + args.validity_string = get_validity_string (pk, uid); + namehash_from_uid (uid); + args.namehash = uid->namehash; if(pk) keyid_from_pk(pk,kid); |