aboutsummaryrefslogtreecommitdiff
path: root/src/inspsocket.cpp
diff options
context:
space:
mode:
authorGravatar Attila Molnar2013-12-18 16:20:40 +0100
committerGravatar Attila Molnar2013-12-18 16:20:40 +0100
commit1e8389b27ff99ad9f48c890486ebef936acafc41 (patch)
tree44543c79a89509604d2fa7b910c278476b9a0eba /src/inspsocket.cpp
parentFix issues discovered by Coverity (diff)
Clean up CoreException
- Remove default constructor - Replace virtual functions returning C strings with functions returning const std::string refs
Diffstat (limited to 'src/inspsocket.cpp')
-rw-r--r--src/inspsocket.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/inspsocket.cpp b/src/inspsocket.cpp
index d7a25785d..8822f69f8 100644
--- a/src/inspsocket.cpp
+++ b/src/inspsocket.cpp
@@ -132,7 +132,7 @@ void StreamSocket::Close()
catch (CoreException& modexcept)
{
ServerInstance->Logs->Log("SOCKET", LOG_DEFAULT, "%s threw an exception: %s",
- modexcept.GetSource(), modexcept.GetReason());
+ modexcept.GetSource().c_str(), modexcept.GetReason().c_str());
}
DelIOHook();
}
@@ -172,7 +172,7 @@ void StreamSocket::DoRead()
catch (CoreException& modexcept)
{
ServerInstance->Logs->Log("SOCKET", LOG_DEFAULT, "%s threw an exception: %s",
- modexcept.GetSource(), modexcept.GetReason());
+ modexcept.GetSource().c_str(), modexcept.GetReason().c_str());
return;
}
if (rv > 0)
@@ -321,7 +321,7 @@ void StreamSocket::DoWrite()
catch (CoreException& modexcept)
{
ServerInstance->Logs->Log("SOCKET", LOG_DEBUG, "%s threw an exception: %s",
- modexcept.GetSource(), modexcept.GetReason());
+ modexcept.GetSource().c_str(), modexcept.GetReason().c_str());
}
}
#ifndef DISABLE_WRITEV
@@ -533,7 +533,7 @@ void StreamSocket::HandleEvent(EventType et, int errornum)
catch (CoreException& ex)
{
ServerInstance->Logs->Log("SOCKET", LOG_DEFAULT, "Caught exception in socket processing on FD %d - '%s'",
- fd, ex.GetReason());
+ fd, ex.GetReason().c_str());
SetError(ex.GetReason());
}
if (!error.empty())