projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d69d951
)
test-clock: fix FILE* leak
author
Martin Pitt
<martin.pitt@ubuntu.com>
Mon, 29 Feb 2016 16:40:08 +0000
(17:40 +0100)
committer
Martin Pitt
<martin.pitt@ubuntu.com>
Mon, 29 Feb 2016 16:40:08 +0000
(17:40 +0100)
Close the FILE* instead of the underlying fd.
src/test/test-clock.c
patch
|
blob
|
history
diff --git
a/src/test/test-clock.c
b/src/test/test-clock.c
index
0949793
..
84f775e
100644
(file)
--- a/
src/test/test-clock.c
+++ b/
src/test/test-clock.c
@@
-28,8
+28,8
@@
static void test_clock_is_localtime(void) {
char adjtime[] = "/tmp/test-adjtime.XXXXXX";
-
_cleanup_close_
int fd = -1;
-
FILE* f
;
+ int fd = -1;
+
_cleanup_fclose_ FILE* f = NULL
;
static const struct scenario {
const char* contents;