projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
700ad38
)
t/memlock: Free allocated memory
author
Bart Van Assche
<bvanassche@acm.org>
Sat, 4 Jan 2020 22:07:54 +0000
(14:07 -0800)
committer
Bart Van Assche
<bvanassche@acm.org>
Sat, 4 Jan 2020 22:39:41 +0000
(14:39 -0800)
This patch fixes the following Coverity complaint:
CID 280679: Resource leaks (RESOURCE_LEAK)
Variable "buf" going out of scope leaks the storage it points to.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
t/memlock.c
patch
|
blob
|
blame
|
history
diff --git
a/t/memlock.c
b/t/memlock.c
index 3d3579ad25292f0369b16f8a71306e9db7a8eea2..ebedb91d4eb67417563fd4e969e52d6b9bf3feec 100644
(file)
--- a/
t/memlock.c
+++ b/
t/memlock.c
@@
-26,6
+26,7
@@
static void *worker(void *data)
first = 0;
}
}
first = 0;
}
}
+ free(buf);
return NULL;
}
return NULL;
}