summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2020-03-19 23:06:24 +0100
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2020-03-19 23:06:24 +0100
commita86266d0479316a7ab654a35828ea2abee8a9059 (patch)
tree3c978985d8e024db0f9a95698cdcc819a8152333
parentd33a935fa3c198923e06c4bc5d7922f178cb7dc6 (diff)
Fix destruction of NULL pointer in xattr reader cleanup
This fixes a copy and paste error in the cleanup path, destroying a previously destroyed object again instead of the one being tested for. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
-rw-r--r--lib/sqfs/xattr_reader.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/sqfs/xattr_reader.c b/lib/sqfs/xattr_reader.c
index bad160d..37f222a 100644
--- a/lib/sqfs/xattr_reader.c
+++ b/lib/sqfs/xattr_reader.c
@@ -117,8 +117,8 @@ int sqfs_xattr_reader_load(sqfs_xattr_reader_t *xr, const sqfs_super_t *super,
}
if (xr->kvrd != NULL) {
- sqfs_destroy(xr->idrd);
- xr->idrd = NULL;
+ sqfs_destroy(xr->kvrd);
+ xr->kvrd = NULL;
}
free(xr->id_block_starts);