Fix: error path if heap_init fails
authorJulien Desfossez <jdesfossez@efficios.com>
Thu, 2 Aug 2012 22:24:43 +0000 (18:24 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Thu, 2 Aug 2012 22:24:43 +0000 (18:24 -0400)
commitbed54c92f5e3c9159b776105d17ab5b4c0d682c7
tree035011c46296196017d94c98de2ece7bdb893f73
parent0be8b6b76e1767f8d5f6b4c974df9a7d01eb91bc
Fix: error path if heap_init fails

Avoid an eventual double-free if heap_init fails in bt_iter_set_pos.

[ Note by Mathieu Desnoyers: the current implementation of heap_init
  ensures that ptrs is set to NULL when it fails, so there is currently
  no double-free situation. But let's not rely on this implementation
  detail that might change in the future. ]

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
lib/iterator.c
This page took 0.03164 seconds and 4 git commands to generate.