summaryrefslogtreecommitdiff
path: root/louloulibs
diff options
context:
space:
mode:
authorlouiz’ <louiz@louiz.org>2016-11-16 20:28:48 +0100
committerlouiz’ <louiz@louiz.org>2016-11-16 20:28:48 +0100
commit9dd0cf8f7aee5c6d3be163246de9f0a5282e02e5 (patch)
treec75b173b8cc377597d5994e82dc62857f8dc58e3 /louloulibs
parent89868e4cda7100840f967860cdebe4fe8024a427 (diff)
downloadbiboumi-9dd0cf8f7aee5c6d3be163246de9f0a5282e02e5.tar.gz
biboumi-9dd0cf8f7aee5c6d3be163246de9f0a5282e02e5.tar.bz2
biboumi-9dd0cf8f7aee5c6d3be163246de9f0a5282e02e5.tar.xz
biboumi-9dd0cf8f7aee5c6d3be163246de9f0a5282e02e5.zip
Fix an error on gcc 4.9, because it is so stupid it can’t find operator""s
Diffstat (limited to 'louloulibs')
-rw-r--r--louloulibs/network/tcp_server_socket.hpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/louloulibs/network/tcp_server_socket.hpp b/louloulibs/network/tcp_server_socket.hpp
index 663ae5b..44d474c 100644
--- a/louloulibs/network/tcp_server_socket.hpp
+++ b/louloulibs/network/tcp_server_socket.hpp
@@ -14,8 +14,6 @@
#include <cstring>
#include <cassert>
-using namespace std::string_literals;
-
template <typename RemoteSocketType>
class TcpSocketServer: public SocketHandler
{
@@ -24,11 +22,11 @@ class TcpSocketServer: public SocketHandler
SocketHandler(poller, -1)
{
if ((this->socket = ::socket(AF_INET6, SOCK_STREAM, 0)) == -1)
- throw std::runtime_error("Could not create socket: "s + std::strerror(errno));
+ throw std::runtime_error(std::string{"Could not create socket: "} + std::strerror(errno));
int opt = 1;
if (::setsockopt(this->socket, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt)) == -1)
- throw std::runtime_error("Failed to set socket option: "s + std::strerror(errno));
+ throw std::runtime_error(std::string{"Failed to set socket option: "} + std::strerror(errno));
struct sockaddr_in6 addr{};
addr.sin6_family = AF_INET6;