commit 09351c34e9bea4d29fb6f4ac8d40e3bee49e12fc Author: rl1987 rl1987@sdf.lonestar.org Date: Thu Feb 22 19:52:40 2018 +0100
Don't strlen before checking for NULL --- src/common/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/common/util.c b/src/common/util.c index 497b60be1..5ae4d0408 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -1079,7 +1079,7 @@ string_is_valid_dest(const char *string) { char *tmp = NULL; int retval; - size_t len = strlen(string); + size_t len;
if (string == NULL) return 0;
tor-commits@lists.torproject.org