From 454e3ff7202666900c55d852317fea01017ed7e3 Mon Sep 17 00:00:00 2001 From: Vincent Malguy Date: Fri, 9 Oct 2015 18:17:35 +0200 Subject: [PATCH] fix use of an unallocated variable --- auth.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/auth.c b/auth.c index ad38ab2..b2048ec 100644 --- a/auth.c +++ b/auth.c @@ -64,7 +64,6 @@ static int derive_key(struct vtun_host *host) unsigned char salt[crypto_pwhash_scryptsalsa208sha256_SALTBYTES]; int ret = -1; size_t bin_len; - const char ** const hex_end; if (host->key != NULL) { return 0; @@ -74,7 +73,7 @@ static int derive_key(struct vtun_host *host) } sodium_hex2bin(host->key, HOST_KEYBYTES,host->passwd, - strlen(host->passwd), "", &bin_len, hex_end); + strlen(host->passwd), "", &bin_len, NULL); if (bin_len == HOST_KEYBYTES) { vtun_syslog(LOG_ERR,"supplied password is long enough to be the secret"); return 0;