From 061e8cae3c4e66b80d2e71048dd037f0443c82cf Mon Sep 17 00:00:00 2001 From: Jonathan McDowell Date: Mon, 31 May 2004 23:48:02 +0000 Subject: [PATCH 1/1] cscvs to tla changeset 105 Author: noodles Date: 2003/10/03 23:24:16 Fix stupid ordering bug with checking we're under the requested number of keys in read_openpgp_stream. --- parsekey.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/parsekey.c b/parsekey.c index b492937..35c14c0 100644 --- a/parsekey.c +++ b/parsekey.c @@ -5,7 +5,7 @@ * * Copyright 2002 Project Purple * - * $Id: parsekey.c,v 1.14 2003/09/30 21:59:33 noodles Exp $ + * $Id: parsekey.c,v 1.15 2003/10/03 23:24:16 noodles Exp $ */ #include @@ -189,8 +189,8 @@ int read_openpgp_stream(int (*getchar_func)(void *ctx, size_t count, } } - while (!rc && !getchar_func(ctx, 1, &curchar) && - (maxnum == 0 || keys < maxnum)) { + while (!rc && (maxnum == 0 || keys < maxnum) && + !getchar_func(ctx, 1, &curchar)) { if (!inpacket && (curchar & 0x80)) { /* * New packet. Record the fact we're in a packet and -- 2.39.5