openbsd-ports/misc/srcpd/patches/patch-src_loconet_c
sebastia 541e99fb7d import misc/srcpd: daemon to control digital model railroad systems
DESCR:
SRCP is an communication protocol designed to integrate all model
railroad systems. Further key features are full multiuser capabilities
and simplified user interface development.
2010-12-11 11:14:54 +00:00

21 lines
663 B
Plaintext

$OpenBSD: patch-src_loconet_c,v 1.1.1.1 2010/12/11 11:14:54 sebastia Exp $
--- src/loconet.c.orig Mon Mar 1 21:21:37 2010
+++ src/loconet.c Tue Dec 7 20:03:27 2010
@@ -11,6 +11,7 @@
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/ioctl.h>
+#include <netinet/in.h>
#include "config.h"
#ifdef HAVE_LINUX_SERIAL_H
@@ -254,7 +255,7 @@ static int init_lineLOCONET_lbserver(bus_t busnumber)
/* Set preferred network connection options, for Cygwin use IPv4-only
* as IPv6 is not supported yet */
-#ifdef __CYGWIN__
+#if defined(__CYGWIN__) || defined(__OpenBSD__)
hi.ai_family = AF_INET;
hi.ai_protocol = IPPROTO_TCP;
#else