aboutsummaryrefslogtreecommitdiff
path: root/games/enigma/files/patch-src-client.cc
diff options
context:
space:
mode:
Diffstat (limited to 'games/enigma/files/patch-src-client.cc')
-rw-r--r--games/enigma/files/patch-src-client.cc25
1 files changed, 25 insertions, 0 deletions
diff --git a/games/enigma/files/patch-src-client.cc b/games/enigma/files/patch-src-client.cc
new file mode 100644
index 000000000000..94a4e7150f23
--- /dev/null
+++ b/games/enigma/files/patch-src-client.cc
@@ -0,0 +1,25 @@
+--- src/client.cc.orig 2011-11-07 19:49:08.000000000 +0100
++++ src/client.cc 2011-11-07 19:53:20.000000000 +0100
+@@ -128,6 +128,9 @@
+
+ m_network_host = enet_host_create (NULL,
+ 1 /* only allow 1 outgoing connection */,
++#if ENET_VERSION > 130
++ 0,
++#endif
+ 57600 / 8 /* 56K modem with 56 Kbps downstream bandwidth */,
+ 14400 / 8 /* 56K modem with 14 Kbps upstream bandwidth */);
+
+@@ -148,8 +151,11 @@
+ sv_address.port = 12345;
+
+ /* Initiate the connection, allocating the two channels 0 and 1. */
++#if ENET_VERSION > 130
++ m_server = enet_host_connect (m_network_host, &sv_address, 2, 0);
++#else
+ m_server = enet_host_connect (m_network_host, &sv_address, 2);
+-
++#endif
+ if (m_server == NULL) {
+ fprintf (stderr,
+ "No available peers for initiating an ENet connection.\n");