mgmt: update face created Control Response with URI's canonical form
refs: #1619
Change-Id: I7c0304ce390de9757d2352e182a075ac902020d2
diff --git a/daemon/mgmt/face-manager.cpp b/daemon/mgmt/face-manager.cpp
index f91a8f8..3833dc4 100644
--- a/daemon/mgmt/face-manager.cpp
+++ b/daemon/mgmt/face-manager.cpp
@@ -812,6 +812,7 @@
{
addCreatedFaceToForwarder(newFace);
parameters.setFaceId(newFace->getId());
+ parameters.setUri(newFace->getRemoteUri().toString());
sendResponse(requestName, 200, "Success", parameters.wireEncode());
}
diff --git a/tests/daemon/mgmt/face-manager.cpp b/tests/daemon/mgmt/face-manager.cpp
index 974e417..e43c142 100644
--- a/tests/daemon/mgmt/face-manager.cpp
+++ b/tests/daemon/mgmt/face-manager.cpp
@@ -1516,7 +1516,7 @@
generateCommand(*command);
ControlParameters resultParameters;
- resultParameters.setUri("tcp://127.0.0.1");
+ resultParameters.setUri("dummy://");
resultParameters.setFaceId(1);
shared_ptr<DummyFace> dummy(make_shared<DummyFace>());