diff options
Diffstat (limited to 'games/eboard/files/patch-c++11')
-rw-r--r-- | games/eboard/files/patch-c++11 | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/games/eboard/files/patch-c++11 b/games/eboard/files/patch-c++11 new file mode 100644 index 000000000000..68b47b914a39 --- /dev/null +++ b/games/eboard/files/patch-c++11 @@ -0,0 +1,17 @@ +libc++ doesn't like "using namespace std" in C++11 + +network.cc:466:59: error: invalid operands to binary expression ('__bind<int &, sockaddr *, unsigned long>' and 'int') + if (bind(netsocket,(struct sockaddr *) &sin,sizeof(sin))==-1) { + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^ ~~ + +--- network.cc.orig 2008-02-22 15:51:22 UTC ++++ network.cc +@@ -463,7 +463,7 @@ int IncomingConnection::createSocket() { + sin.sin_addr.s_addr = INADDR_ANY; + sin.sin_port = htons(Port); + +- if (bind(netsocket,(struct sockaddr *) &sin,sizeof(sin))==-1) { ++ if (::bind(netsocket,(struct sockaddr *) &sin,sizeof(sin))==-1) { + snprintf(errorMessage,128,_("Unable to bind on port %d."),Port); + return(-1); + } |