summaryrefslogtreecommitdiff
path: root/src/socketengines
diff options
context:
space:
mode:
Diffstat (limited to 'src/socketengines')
-rw-r--r--src/socketengines/socketengine_eventfd.cpp2
-rw-r--r--src/socketengines/socketengine_pipe.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/socketengines/socketengine_eventfd.cpp b/src/socketengines/socketengine_eventfd.cpp
index 767a6eddb..a0efe5286 100644
--- a/src/socketengines/socketengine_eventfd.cpp
+++ b/src/socketengines/socketengine_eventfd.cpp
@@ -16,7 +16,7 @@ Pipe::Pipe() : Socket()
{
this->Sock = eventfd(0, EFD_NONBLOCK);
if (this->Sock < 0)
- throw CoreException(Anope::string("Could not create pipe: ") + strerror(errno));
+ throw CoreException(Anope::string("Could not create pipe: ") + Anope::LastError());
this->IPv6 = false;
this->Type = SOCKTYPE_CLIENT;
diff --git a/src/socketengines/socketengine_pipe.cpp b/src/socketengines/socketengine_pipe.cpp
index 0b319f0b0..b0be664c8 100644
--- a/src/socketengines/socketengine_pipe.cpp
+++ b/src/socketengines/socketengine_pipe.cpp
@@ -17,7 +17,7 @@ Pipe::Pipe() : Socket()
{
int fds[2];
if (pipe(fds))
- throw CoreException(Anope::string("Could not create pipe: ") + strerror(errno));
+ throw CoreException(Anope::string("Could not create pipe: ") + Anope::LastError());
int flags = fcntl(fds[0], F_GETFL, 0);
fcntl(fds[0], F_SETFL, flags | O_NONBLOCK);
flags = fcntl(fds[1], F_GETFL, 0);