From 663860bf5e3e3df1081900ed03d8cc63c483b42d Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Sun, 28 Aug 2011 06:35:37 +0200 Subject: [PATCH] string: Set result pointer to NULL on errors. ...and be strict in what you return. --- string.c | 1 + 1 file changed, 1 insertion(+) diff --git a/string.c b/string.c index b16109ca..0a32c0f4 100644 --- a/string.c +++ b/string.c @@ -762,6 +762,7 @@ err: while (num_words > 0) free(argv[--num_words]); free(argv); + *result = NULL; return ret; } -- 2.39.2