summaryrefslogtreecommitdiff
path: root/service/One.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2015-04-14 13:56:28 -0700
committerAdam Ierymenko <adam.ierymenko@gmail.com>2015-04-14 13:56:28 -0700
commit1cfa67bbdd4242a52484f13f3533babb4d4c07a6 (patch)
treed772b3b7cc40371afaa494c4e623511133e0e33e /service/One.cpp
parenta2605561af19d7de7ed492d1faf00d7ff161c6ea (diff)
downloadinfinitytier-1cfa67bbdd4242a52484f13f3533babb4d4c07a6.tar.gz
infinitytier-1cfa67bbdd4242a52484f13f3533babb4d4c07a6.zip
Bunch more control plane work, and shelve old UI -- React FTW.
Diffstat (limited to 'service/One.cpp')
-rw-r--r--service/One.cpp18
1 files changed, 7 insertions, 11 deletions
diff --git a/service/One.cpp b/service/One.cpp
index 08210da1..5e81bc61 100644
--- a/service/One.cpp
+++ b/service/One.cpp
@@ -189,7 +189,7 @@ public:
if (_master)
_node->setNetconfMaster((void *)_master);
- _controlPlane = new ControlPlane(_node,std::set<std::string>());
+ _controlPlane = new ControlPlane(_node);
_nextBackgroundTaskDeadline = 0;
for(;;) {
@@ -454,16 +454,12 @@ public:
std::string contentType("text/plain"); // default if not changed in handleRequest()
unsigned int scode = 404;
- if ((htc->from.ipsEqual(InetAddress::LO4))||(htc->from.ipsEqual(InetAddress::LO6))) {
- try {
- if (_controlPlane)
- scode = _controlPlane->handleRequest(htc->parser.method,htc->url,htc->headers,htc->body,data,contentType);
- } catch ( ... ) {
- scode = 500;
- }
- } else {
- scode = 403;
- htc->shouldKeepAlive = false;
+ try {
+ if (_controlPlane)
+ scode = _controlPlane->handleRequest(htc->from,htc->parser.method,htc->url,htc->headers,htc->body,data,contentType);
+ else scode = 500;
+ } catch ( ... ) {
+ scode = 500;
}
const char *scodestr;