summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/sys
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/qpid/sys')
-rw-r--r--cpp/src/qpid/sys/AsynchIOAcceptor.cpp7
-rw-r--r--cpp/src/qpid/sys/Serializer.cpp4
2 files changed, 5 insertions, 6 deletions
diff --git a/cpp/src/qpid/sys/AsynchIOAcceptor.cpp b/cpp/src/qpid/sys/AsynchIOAcceptor.cpp
index 8d6b543dc9..93cf35a043 100644
--- a/cpp/src/qpid/sys/AsynchIOAcceptor.cpp
+++ b/cpp/src/qpid/sys/AsynchIOAcceptor.cpp
@@ -159,19 +159,18 @@ void AsynchIOAcceptor::run(ConnectionInputHandlerFactory* fact) {
boost::bind(&AsynchIOAcceptor::accepted, this, poller, _1, fact));
acceptor.start(poller);
- std::vector<Thread*> t(numIOThreads-1);
+ std::vector<Thread> t(numIOThreads-1);
// Run n-1 io threads
for (int i=0; i<numIOThreads-1; ++i)
- t[i] = new Thread(d);
+ t[i] = Thread(d);
// Run final thread
d.run();
// Now wait for n-1 io threads to exit
for (int i=0; i>numIOThreads-1; ++i) {
- t[i]->join();
- delete t[i];
+ t[i].join();
}
}
diff --git a/cpp/src/qpid/sys/Serializer.cpp b/cpp/src/qpid/sys/Serializer.cpp
index cdc8b91694..faf94a0f93 100644
--- a/cpp/src/qpid/sys/Serializer.cpp
+++ b/cpp/src/qpid/sys/Serializer.cpp
@@ -55,11 +55,11 @@ void Serializer::dispatch(Task& task) {
try {
task();
} catch (const std::exception& e) {
- QPID_LOG(error, "Unexpected exception in Serializer::dispatch"
+ QPID_LOG(critical, "Unexpected exception in Serializer::dispatch"
<< e.what());
assert(0); // Should not happen.
} catch (...) {
- QPID_LOG(error, "Unexpected exception in Serializer::dispatch.");
+ QPID_LOG(critical, "Unexpected exception in Serializer::dispatch.");
assert(0); // Should not happen.
}
}