summaryrefslogtreecommitdiff
path: root/src/lib/json_server.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-11-27 18:42:07 +0000
committerCarl Hetherington <cth@carlh.net>2015-11-27 18:42:07 +0000
commit18c3b488dff343a9b287d8d0fd68143b792ec75e (patch)
tree8beb9ca8400a68a8406b52737f90cafd4eafbc14 /src/lib/json_server.cc
parent2a02b09b9df160d6c83874d0ac2ae5f16bd50bb5 (diff)
Fix some stringstreams that had crept in.
Diffstat (limited to 'src/lib/json_server.cc')
-rw-r--r--src/lib/json_server.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/json_server.cc b/src/lib/json_server.cc
index c7a3ca144..38d5501c5 100644
--- a/src/lib/json_server.cc
+++ b/src/lib/json_server.cc
@@ -29,7 +29,6 @@
#include <iostream>
using std::string;
-using std::stringstream;
using std::cout;
using std::map;
using std::list;
@@ -151,7 +150,7 @@ JSONServer::request (string url, shared_ptr<tcp::socket> socket)
action = r["action"];
}
- stringstream json;
+ SafeStringStream json;
if (action == "status") {
list<shared_ptr<Job> > jobs = JobManager::instance()->get ();
@@ -187,7 +186,7 @@ JSONServer::request (string url, shared_ptr<tcp::socket> socket)
}
}
- stringstream reply;
+ SafeStringStream reply;
reply << "HTTP/1.1 200 OK\r\n"
<< "Content-Length: " << json.str().length() << "\r\n"
<< "Content-Type: application/json\r\n"