summaryrefslogtreecommitdiff
path: root/src/glibext
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2016-02-02 23:51:27 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2016-02-02 23:51:27 (GMT)
commit1a5aafe8e1c64289e438a277ac05d9e9a0f1bd49 (patch)
tree0a6d521fa3dfedd0d4d757ec01b81a7f6f265af0 /src/glibext
parenta61984e52bfd35e19408b7cbdb11e3419f635829 (diff)
Prevented access to uninitialised memory.
Diffstat (limited to 'src/glibext')
-rw-r--r--src/glibext/gbinportion.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/glibext/gbinportion.c b/src/glibext/gbinportion.c
index 0744a79..454fc6b 100644
--- a/src/glibext/gbinportion.c
+++ b/src/glibext/gbinportion.c
@@ -1003,6 +1003,8 @@ GBinPortion **g_portion_layer_collect_all_portions(const GPortionLayer *layer, s
}
+ *count = 0;
+
result = do_collect(layer, NULL, count);
qsort(result, *count, sizeof(GBinPortion *), (__compar_fn_t)g_binary_portion_compare);