summaryrefslogtreecommitdiffstats
path: root/polyp/socket-util.c
diff options
context:
space:
mode:
Diffstat (limited to 'polyp/socket-util.c')
-rw-r--r--polyp/socket-util.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/polyp/socket-util.c b/polyp/socket-util.c
index 904381b7..f9d0febf 100644
--- a/polyp/socket-util.c
+++ b/polyp/socket-util.c
@@ -121,8 +121,10 @@ int pa_socket_tcp_low_delay(int fd) {
int pa_socket_set_rcvbuf(int fd, size_t l) {
assert(fd >= 0);
- if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &l, sizeof(l)) < 0)
+ if (setsockopt(fd, SOL_SOCKET, SO_RCVBUF, &l, sizeof(l)) < 0) {
+ fprintf(stderr, "SO_RCVBUF: %s\n", strerror(errno));
return -1;
+ }
return 0;
}
@@ -130,8 +132,10 @@ int pa_socket_set_rcvbuf(int fd, size_t l) {
int pa_socket_set_sndbuf(int fd, size_t l) {
assert(fd >= 0);
- if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, &l, sizeof(l)) < 0)
+ if (setsockopt(fd, SOL_SOCKET, SO_SNDBUF, &l, sizeof(l)) < 0) {
+ fprintf(stderr, "SO_SNDBUF: %s\n", strerror(errno));
return -1;
+ }
return 0;
}