aboutsummaryrefslogtreecommitdiff
path: root/ssl.c
diff options
context:
space:
mode:
authorDavid Sommerseth <dazo@users.sourceforge.net>2010-04-17 21:03:06 +0200
committerDavid Sommerseth <dazo@users.sourceforge.net>2010-10-21 11:37:03 +0200
commitd2bf22af84a1758d6ba281cd22e4ff44a7bb40c6 (patch)
tree8385ab43d6c3c6fc481024356449e9f2a1df9400 /ssl.c
parentRemoved no longer needed delete_file() call (diff)
downloadopenvpn-d2bf22af84a1758d6ba281cd22e4ff44a7bb40c6.tar.xz
Fixed potential NULL pointer issue
If create_temp_file() returns NULL, this strlen() check would cause a SEGV. Signed-off-by: David Sommerseth <dazo@users.sourceforge.net> Acked-by: Gert Doering <gert@greenie.muc.de>
Diffstat (limited to 'ssl.c')
-rw-r--r--ssl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ssl.c b/ssl.c
index 94f98b1..1ed5ace 100644
--- a/ssl.c
+++ b/ssl.c
@@ -3265,7 +3265,7 @@ verify_user_pass_script (struct tls_session *session, const struct user_pass *up
}
done:
- if (strlen (tmp_file) > 0)
+ if (tmp_file && strlen (tmp_file) > 0)
delete_file (tmp_file);
argv_reset (&argv);