diff options
author | Lennart Poettering <lennart@poettering.net> | 2012-01-05 21:39:31 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2012-01-05 21:39:31 +0100 |
commit | 86b9b8e70d54e79db3ff4f67bbd5280ecfc82537 (patch) | |
tree | 43ac4daf526a0061ab5d3219d14a789f6a4c1f70 /src | |
parent | 54fe0cdbe313558a712a15dc3bc516a46c1f7b6e (diff) |
sd-journal: close reading side of sd_journal_stream_fd() file descriptors
Diffstat (limited to 'src')
-rw-r--r-- | src/journal/journal-send.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/journal/journal-send.c b/src/journal/journal-send.c index 176aac2792..c382264682 100644 --- a/src/journal/journal-send.c +++ b/src/journal/journal-send.c @@ -233,6 +233,11 @@ _public_ int sd_journal_stream_fd(const char *tag, int priority, int priority_pr return -errno; } + if (shutdown(fd, SHUT_RD) < 0) { + close_nointr_nofail(fd); + return -errno; + } + if (!tag) tag = ""; |