diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-12-19 13:20:30 +0100 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2022-12-19 15:00:59 +0100 |
commit | 3401477982d09e0c9815ae5a69e56f43f187967e (patch) | |
tree | fdf3ce225df76b9e643835928dc29aeef02a51fc /src/fuzz | |
parent | a5937dcf3902ecb90777f259f6e006292eb54251 (diff) | |
download | systemd-3401477982d09e0c9815ae5a69e56f43f187967e.tar.gz |
tree-wide: use -EBADF also in pipe initializers
In some places, initialization is dropped when unnecesary.
Diffstat (limited to 'src/fuzz')
-rw-r--r-- | src/fuzz/fuzz-varlink.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/fuzz/fuzz-varlink.c b/src/fuzz/fuzz-varlink.c index 397c20dca6..c97586be9e 100644 --- a/src/fuzz/fuzz-varlink.c +++ b/src/fuzz/fuzz-varlink.c @@ -85,7 +85,7 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { struct iovec server_iov = IOVEC_MAKE((void*) data, size), client_iov = IOVEC_MAKE((void*) data, size); /* Important: the declaration order matters here! we want that the fds are closed on return after the * event sources, hence we declare the fds first, the event sources second */ - _cleanup_close_pair_ int server_pair[2] = { -1, -1 }, client_pair[2] = { -1, -1 }; + _cleanup_close_pair_ int server_pair[2] = { -EBADF, -EBADF }, client_pair[2] = { -EBADF, -EBADF }; _cleanup_(sd_event_source_unrefp) sd_event_source *idle_event_source = NULL, *server_event_source = NULL, *client_event_source = NULL; _cleanup_(varlink_server_unrefp) VarlinkServer *s = NULL; |