Fix false ***buffer overflow*** detection
[src/app-framework-binder.git] / src / globset.c
index 228d852..fa37884 100644 (file)
@@ -323,7 +323,7 @@ int globset_add(
        }
 
        /* not found, create it */
-       ph = malloc(len + sizeof *ph);
+       ph = malloc(1 + len + sizeof *ph);
        if (!ph)
                return -1;