]> git.ipfire.org Git - pakfire.git/commit
pakfire_free: Avoid multiple calls
authorMichael Tremer <michael.tremer@ipfire.org>
Tue, 5 Oct 2021 11:59:20 +0000 (11:59 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 5 Oct 2021 11:59:20 +0000 (11:59 +0000)
commitc8d72bf89c4f3bb367ac240bb7d0c6ae2a47971d
treed921faa10196d80d8f8eac175d215cae48c3ec97
parent93d45f3c299edc30c236f94dc0967d3acb050d02
pakfire_free: Avoid multiple calls

If we want to access any objects that use reference counting, we will
increment and then decrement the reference counter of struct pakfire.
This will cause that pakfire_free() will be called multiple times which
will go wrong.

This change blocks that that will happen.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/libpakfire/pakfire.c