Summary: | spice FTBFS on debian kfreebsd-* | ||
---|---|---|---|
Product: | Spice | Reporter: | Laurent Bigonville <bigon> |
Component: | server | Assignee: | Spice Bug List <spice-bugs> |
Status: | RESOLVED MOVED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | CC: | teuf |
Version: | unspecified | ||
Hardware: | Other | ||
OS: | All | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Laurent Bigonville
2016-12-28 20:17:07 UTC
On FreeBSD older than 9.1, it seems TCP_KEEPIDLE is not available and does not have a replacement ( https://lists.freebsd.org/pipermail/freebsd-net/2013-May/035496.html ). I don't know if this means anything for kfreebsd though. One way of handling this is to wrap its use in #ifdef TCP_KEEPIDLE diff --git a/server/reds.c b/server/reds.c index 6064a6d..0c8fb35 100644 --- a/server/reds.c +++ b/server/reds.c @@ -2329,7 +2329,9 @@ static void reds_handle_ssl_accept(int fd, int event, void *data) static bool reds_init_keepalive(int socket) { int keepalive = 1; +#ifdef TCP_KEEPIDLE int keepalive_timeout = KEEPALIVE_TIMEOUT; +#endif if (setsockopt(socket, SOL_SOCKET, SO_KEEPALIVE, &keepalive, sizeof(keepalive)) == -1) { if (errno != ENOTSUP) { @@ -2338,6 +2340,7 @@ static bool reds_init_keepalive(int socket) } } +#ifdef TCP_KEEPIDLE if (setsockopt(socket, SOL_TCP, TCP_KEEPIDLE, &keepalive_timeout, sizeof(keepalive_timeout)) == -1) { if (errno != ENOTSUP) { @@ -2345,6 +2348,7 @@ static bool reds_init_keepalive(int socket) return false; } } +#endif return true; } I would add AC_CHECK_DECL for the symbol, so the info that it is unavailable is in the config log -- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/spice/spice-server/issues/4. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.