summaryrefslogtreecommitdiff
path: root/indra/llmessage/tests
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2016-10-11 10:59:17 -0400
committerNat Goodspeed <nat@lindenlab.com>2016-10-11 10:59:17 -0400
commit704c53b3c506c1274981b3e1ca5a22c16e4fbbb4 (patch)
tree258785e6ebcd41009e6ef160a5d7b8e9ed218f94 /indra/llmessage/tests
parenteb8961235f7dcb03e3fe8ae2d02929d97cc5d7d7 (diff)
parent086c1342152895da28d2e0130d09432152604ca8 (diff)
MAINT-5232: Merge up to VLC viewer from viewer-release
Diffstat (limited to 'indra/llmessage/tests')
-rw-r--r--indra/llmessage/tests/commtest.h8
-rw-r--r--indra/llmessage/tests/networkio.h5
2 files changed, 7 insertions, 6 deletions
diff --git a/indra/llmessage/tests/commtest.h b/indra/llmessage/tests/commtest.h
index 0d149b5258..7c8f27bbd2 100644
--- a/indra/llmessage/tests/commtest.h
+++ b/indra/llmessage/tests/commtest.h
@@ -33,15 +33,15 @@
#include "llevents.h"
#include "llsd.h"
#include "llhost.h"
+#include "llexception.h"
#include "stringize.h"
#include <map>
#include <string>
-#include <stdexcept>
#include <boost/lexical_cast.hpp>
-struct CommtestError: public std::runtime_error
+struct CommtestError: public LLException
{
- CommtestError(const std::string& what): std::runtime_error(what) {}
+ CommtestError(const std::string& what): LLException(what) {}
};
static bool query_verbose()
@@ -68,7 +68,7 @@ static int query_port(const std::string& var)
const char* cport = getenv(var.c_str());
if (! cport)
{
- throw CommtestError(STRINGIZE("missing environment variable" << var));
+ LLTHROW(CommtestError(STRINGIZE("missing environment variable" << var)));
}
// This will throw, too, if the value of PORT isn't numeric.
int port(boost::lexical_cast<int>(cport));
diff --git a/indra/llmessage/tests/networkio.h b/indra/llmessage/tests/networkio.h
index e579b2fb89..5986524342 100644
--- a/indra/llmessage/tests/networkio.h
+++ b/indra/llmessage/tests/networkio.h
@@ -34,6 +34,7 @@
#include "llares.h"
#include "llpumpio.h"
#include "llhttpclient.h"
+#include "llexception.h"
/*****************************************************************************
* NetworkIO
@@ -51,7 +52,7 @@ class NetworkIO: public LLSingleton<NetworkIO>
ll_init_apr();
if (! gAPRPoolp)
{
- throw std::runtime_error("Can't initialize APR");
+ LLTHROW(LLException("Can't initialize APR"));
}
// Create IO Pump to use for HTTP Requests.
@@ -59,7 +60,7 @@ class NetworkIO: public LLSingleton<NetworkIO>
LLHTTPClient::setPump(*mServicePump);
if (ll_init_ares() == NULL || !gAres->isInitialized())
{
- throw std::runtime_error("Can't start DNS resolver");
+ LLTHROW(LLException("Can't start DNS resolver"));
}
// You can interrupt pump() without waiting the full timeout duration