From 486e85962bc24cb020a80a446e37a172e7ca7de7 Mon Sep 17 00:00:00 2001 From: Ben Kibbey Date: Sat, 8 Mar 2008 16:01:12 -0500 Subject: [PATCH] Make sure OPTION ITERATIONS is >= -1. --- src/commands.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/commands.c b/src/commands.c index 1081ecce..cce6aa7b 100644 --- a/src/commands.c +++ b/src/commands.c @@ -2568,7 +2568,7 @@ static int option_handler(assuan_context_t ctx, const gchar *name, errno = 0; n = strtol(value, &p, 10); - if (errno || (p && *p)) + if (errno || (p && *p) || n < -1) return gpg_err_make(PWMD_ERR_SOURCE, GPG_ERR_INV_VALUE); g_key_file_set_integer(keyfileh, client->filename ? client->filename : "global", "iterations", n); -- 2.11.4.GIT