OSDN Git Service
(root)
/
android-x86
/
external-exfat.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
449b965
)
Fix memory leak on error path when directory read fails.
author
relan
<relan@users.noreply.github.com>
Sat, 12 Nov 2016 06:48:06 +0000
(09:48 +0300)
committer
relan
<relan@users.noreply.github.com>
Sat, 12 Nov 2016 06:49:33 +0000
(09:49 +0300)
libexfat/node.c
patch
|
blob
|
history
diff --git
a/libexfat/node.c
b/libexfat/node.c
index
fa04e25
..
3f49fb2
100644
(file)
--- a/
libexfat/node.c
+++ b/
libexfat/node.c
@@
-109,6
+109,7
@@
static int opendir(struct exfat* ef, const struct exfat_node* dir,
if (exfat_pread(ef->dev, it->chunk, CLUSTER_SIZE(*ef->sb),
exfat_c2o(ef, it->cluster)) < 0)
{
+ free(it->chunk);
exfat_error("failed to read directory cluster %#x", it->cluster);
return -EIO;
}