aboutsummaryrefslogtreecommitdiff
path: root/src/daemon
diff options
context:
space:
mode:
Diffstat (limited to 'src/daemon')
-rw-r--r--src/daemon/command_parser_executor.cpp1
-rw-r--r--src/daemon/command_server.cpp1
-rw-r--r--src/daemon/daemon.cpp6
-rw-r--r--src/daemon/p2p.h2
-rw-r--r--src/daemon/protocol.h2
-rw-r--r--src/daemon/rpc.h4
-rw-r--r--src/daemon/rpc_command_executor.cpp3
7 files changed, 11 insertions, 8 deletions
diff --git a/src/daemon/command_parser_executor.cpp b/src/daemon/command_parser_executor.cpp
index 0b42257e7..c48b836e9 100644
--- a/src/daemon/command_parser_executor.cpp
+++ b/src/daemon/command_parser_executor.cpp
@@ -26,6 +26,7 @@
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#include "common/exception.h"
#include "cryptonote_core/cryptonote_basic_impl.h"
#include "daemon/command_parser_executor.h"
diff --git a/src/daemon/command_server.cpp b/src/daemon/command_server.cpp
index 206de9d4a..7e5139636 100644
--- a/src/daemon/command_server.cpp
+++ b/src/daemon/command_server.cpp
@@ -26,6 +26,7 @@
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#include "common/exception.h"
#include "cryptonote_config.h"
#include "version.h"
#include "daemon/command_server.h"
diff --git a/src/daemon/daemon.cpp b/src/daemon/daemon.cpp
index e79823d08..d44538358 100644
--- a/src/daemon/daemon.cpp
+++ b/src/daemon/daemon.cpp
@@ -110,7 +110,7 @@ bool t_daemon::run(bool interactive)
{
if (nullptr == mp_internals)
{
- throw std::runtime_error{"Can't run stopped daemon"};
+ throw tools::runtime_error{"Can't run stopped daemon"};
}
tools::signal_handler::install(std::bind(&daemonize::t_daemon::stop_p2p, this));
@@ -155,7 +155,7 @@ void t_daemon::stop()
{
if (nullptr == mp_internals)
{
- throw std::runtime_error{"Can't stop stopped daemon"};
+ throw tools::runtime_error{"Can't stop stopped daemon"};
}
mp_internals->p2p.stop();
mp_internals->rpc.stop();
@@ -166,7 +166,7 @@ void t_daemon::stop_p2p()
{
if (nullptr == mp_internals)
{
- throw std::runtime_error{"Can't send stop signal to a stopped daemon"};
+ throw tools::runtime_error{"Can't send stop signal to a stopped daemon"};
}
mp_internals->p2p.get().send_stop_signal();
}
diff --git a/src/daemon/p2p.h b/src/daemon/p2p.h
index 3858989ce..b74a5e72d 100644
--- a/src/daemon/p2p.h
+++ b/src/daemon/p2p.h
@@ -60,7 +60,7 @@ public:
LOG_PRINT_L0("Initializing p2p server...");
if (!m_server.init(vm))
{
- throw std::runtime_error("Failed to initialize p2p server.");
+ throw tools::runtime_error("Failed to initialize p2p server.");
}
LOG_PRINT_L0("P2p server initialized OK");
}
diff --git a/src/daemon/protocol.h b/src/daemon/protocol.h
index 8e2add4a2..5f6c317b1 100644
--- a/src/daemon/protocol.h
+++ b/src/daemon/protocol.h
@@ -50,7 +50,7 @@ public:
LOG_PRINT_L0("Initializing cryptonote protocol...");
if (!m_protocol.init(vm))
{
- throw std::runtime_error("Failed to initialize cryptonote protocol.");
+ throw tools::runtime_error("Failed to initialize cryptonote protocol.");
}
LOG_PRINT_L0("Cryptonote protocol initialized OK");
}
diff --git a/src/daemon/rpc.h b/src/daemon/rpc.h
index bfd2afd84..caeae9a3d 100644
--- a/src/daemon/rpc.h
+++ b/src/daemon/rpc.h
@@ -55,7 +55,7 @@ public:
LOG_PRINT_L0("Initializing core rpc server...");
if (!m_server.init(vm))
{
- throw std::runtime_error("Failed to initialize core rpc server.");
+ throw tools::runtime_error("Failed to initialize core rpc server.");
}
LOG_PRINT_GREEN("Core rpc server initialized OK on port: " << m_server.get_binded_port(), LOG_LEVEL_0);
}
@@ -65,7 +65,7 @@ public:
LOG_PRINT_L0("Starting core rpc server...");
if (!m_server.run(2, false))
{
- throw std::runtime_error("Failed to start core rpc server.");
+ throw tools::runtime_error("Failed to start core rpc server.");
}
LOG_PRINT_L0("Core rpc server started ok");
}
diff --git a/src/daemon/rpc_command_executor.cpp b/src/daemon/rpc_command_executor.cpp
index ffda7cde3..13cc5fadc 100644
--- a/src/daemon/rpc_command_executor.cpp
+++ b/src/daemon/rpc_command_executor.cpp
@@ -28,6 +28,7 @@
//
// Parts of this file are originally copyright (c) 2012-2013 The Cryptonote developers
+#include "common/exception.h"
#include "string_tools.h"
#include "common/scoped_message_writer.h"
#include "daemon/rpc_command_executor.h"
@@ -88,7 +89,7 @@ t_rpc_command_executor::t_rpc_command_executor(
{
if (rpc_server == NULL)
{
- throw std::runtime_error("If not calling commands via RPC, rpc_server pointer must be non-null");
+ throw tools::runtime_error("If not calling commands via RPC, rpc_server pointer must be non-null");
}
}