aboutsummaryrefslogtreecommitdiffstats
path: root/agent/genkey.c
diff options
context:
space:
mode:
authorNeal H. Walfield <[email protected]>2015-11-23 21:13:56 +0000
committerNeal H. Walfield <[email protected]>2015-11-23 21:23:37 +0000
commit5b84b0d660c8329e184d98682665aaea7e1703d2 (patch)
tree7eb86d1423780c332b27daa9226e1144e451bcb3 /agent/genkey.c
parentdirmngr: Fix http lookups when libadns is used. (diff)
downloadgnupg-5b84b0d660c8329e184d98682665aaea7e1703d2.tar.gz
gnupg-5b84b0d660c8329e184d98682665aaea7e1703d2.zip
common: Extend utf8_charcount to include the string's length.
* common/stringhelp.c (utf8_charcount): Take additional parameter, len. Process at most LEN bytes. -- Signed-off-by: Neal H. Walfield <[email protected]>
Diffstat (limited to 'agent/genkey.c')
-rw-r--r--agent/genkey.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/agent/genkey.c b/agent/genkey.c
index b780c5049..2eec974d3 100644
--- a/agent/genkey.c
+++ b/agent/genkey.c
@@ -221,7 +221,7 @@ check_passphrase_constraints (ctrl_t ctrl, const char *pw,
/* Now check the constraints and collect the error messages unless
in in silent mode which returns immediately. */
- if (utf8_charcount (pw) < minlen )
+ if (utf8_charcount (pw, -1) < minlen )
{
if (!failed_constraint)
{