Skip to content

Commit 6408d56

Browse files
committed
examples/client/sshtunnel: include headers req'd by some OS's
...namely FreeBSD where accept requires <sys/types.h> and <sys/socket.h> and close requires <unistd.h>. Closes #548
1 parent 0226364 commit 6408d56

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

examples/client/sshtunnel.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,15 @@
1616
#include <netdb.h>
1717
#include <signal.h>
1818
#include <errno.h>
19+
#ifdef LIBVNCSERVER_HAVE_SYS_TYPES_H
20+
#include <sys/types.h>
21+
#endif
22+
#ifdef LIBVNCSERVER_HAVE_SYS_SOCKET_H
23+
#include <sys/socket.h>
24+
#endif
25+
#ifdef LIBVNCSERVER_HAVE_UNISTD_H
26+
#include <unistd.h>
27+
#endif
1928

2029
/* The one global bool that's global so we can set it via
2130
a signal handler... */

0 commit comments

Comments
 (0)