]> git.ipfire.org Git - thirdparty/make.git/commitdiff
* function.c (func_if): Check the first character of condition.
authorPaul Smith <psmith@gnu.org>
Sat, 28 Oct 2017 19:28:32 +0000 (15:28 -0400)
committerPaul Smith <psmith@gnu.org>
Mon, 30 Oct 2017 21:07:21 +0000 (17:07 -0400)
Reported by Rob W <robw9739@gmail.com>

function.c

index c70c155eb4a2a7a8c1a3509e7b81a9344241fbeb..edfacdf1b01abc580e474a37d863b2b28ce73343 100644 (file)
@@ -1245,7 +1245,7 @@ func_if (char *o, char **argv, const char *funcname UNUSED)
     {
       char *expansion = expand_argument (begp, endp+1);
 
-      result = strlen (expansion);
+      result = expansion[0] != '\0';
       free (expansion);
     }