projects
/
platform
/
upstream
/
avahi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
28948f7
)
chroot: suppress error messages if the chroot pipe is closed
author
Lennart Poettering
<lennart@poettering.net>
Tue, 8 Mar 2011 22:57:50 +0000
(23:57 +0100)
committer
Lennart Poettering
<lennart@poettering.net>
Tue, 8 Mar 2011 22:57:50 +0000
(23:57 +0100)
avahi-daemon/chroot.c
patch
|
blob
|
history
diff --git
a/avahi-daemon/chroot.c
b/avahi-daemon/chroot.c
index
d796a39
..
ccd56be
100644
(file)
--- a/
avahi-daemon/chroot.c
+++ b/
avahi-daemon/chroot.c
@@
-394,12
+394,14
@@
int avahi_chroot_helper_unlink(const char *fname) {
return -1;
}
- if (write(helper_fd, &command, sizeof(command)) < 0) {
+ if (write(helper_fd, &command, sizeof(command)) < 0 &&
+ (errno != EPIPE && errno != ECONNRESET)) {
avahi_log_error("write() failed: %s\n", strerror(errno));
return -1;
}
- if ((r = read(helper_fd, &c, sizeof(c))) < 0) {
+ if ((r = read(helper_fd, &c, sizeof(c))) < 0 &&
+ (errno != EPIPE && errno != ECONNRESET)) {
avahi_log_error("read() failed: %s\n", r < 0 ? strerror(errno) : "EOF");
return -1;
}