diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2020-09-14 22:32:52 +0200 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2020-09-14 22:32:52 +0200 |
commit | 649bde89caccdb1187ac744bd76051fdcd687218 (patch) | |
tree | 9df9f579985b93183d17658486ddca7b8ba45eee /src/test/test-fileio.c | |
parent | Merge pull request #17031 from poettering/path-start-limit (diff) | |
download | systemd-649bde89caccdb1187ac744bd76051fdcd687218.tar.xz systemd-649bde89caccdb1187ac744bd76051fdcd687218.zip |
test: use pclose() for popen()
Coverity CID#1432701.
Diffstat (limited to 'src/test/test-fileio.c')
-rw-r--r-- | src/test/test-fileio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/test-fileio.c b/src/test/test-fileio.c index 9c0b3533c2..ce5af43db5 100644 --- a/src/test/test-fileio.c +++ b/src/test/test-fileio.c @@ -153,7 +153,7 @@ static void test_parse_env_file(void) { static void test_one_shell_var(const char *file, const char *variable, const char *value) { _cleanup_free_ char *cmd = NULL, *from_shell = NULL; - _cleanup_fclose_ FILE *f = NULL; + _cleanup_pclose_ FILE *f = NULL; size_t sz; assert_se(cmd = strjoin(". ", file, " && /bin/echo -n \"$", variable, "\"")); |