]> git.sur5r.net Git - i3/i3/commitdiff
Set marks to NULL after freeing
authorOrestis Floros <orestisf1993@gmail.com>
Thu, 7 Sep 2017 00:53:28 +0000 (03:53 +0300)
committerMichael Stapelberg <michael@stapelberg.de>
Thu, 7 Sep 2017 12:56:17 +0000 (14:56 +0200)
realloc() was being called on an already freed pointer.

Fixes #2900

src/load_layout.c

index 632c6ec76f737d25d3cf78771455e4b15b6fc942..7961e17f96a2ef75e420014d99802634c75e995d 100644 (file)
@@ -157,6 +157,7 @@ static int json_end_map(void *ctx) {
             }
 
             free(marks);
+            marks = NULL;
             num_marks = 0;
         }