1

Unable start service alljoyn-gwagent after running the 'sudo service alljoyn start'

Checked the log at /var/log/alljoyn-gwagent. log, it has

0.685 ****** ERROR STRING external ...yn/common/src/String.cc:94 | Constructing string from nullptr will cause a crash in future versions!: ER_WARNING alljoyn-gwagent: /root/alljoyn/core/alljoyn/common/src/String.cc:95: qcc::String::String(const char*): Assertion `str != nullptr' failed.

Followed exact steps at except that we are on master branch https://wiki.allseenalliance.org/gateway/getting_started

Any help would be much appreciated. Thanks in advance!

EDIT: It worked when we tried with branch RB14.12 with the same steps!!!

Aksel Fatih
  • 1,419
  • 18
  • 31
Jayasagar
  • 2,046
  • 19
  • 22

1 Answers1

0

There was a known bug in the project. You can fix it by applying the following patch.

    @@ -222,7 +222,7 @@ void GatewayConnectorAppManifest::parseObjects(xmlNode* currentKey, Capabilities
                 xmlFree(xmlInterfaceFriendly);
                 qcc::String interfaceName = (const char*)interfaceKey->children->content;
                 xmlChar*xmlSecured = xmlGetProp(interfaceKey, (const xmlChar*)"secured");
-                qcc::String secured = (const char*)xmlSecured;
+                qcc::String secured = xmlSecured ? (const char*)xmlSecured : "";
                 xmlFree(xmlSecured);
                 if (secured.compare("true") == 0) {

The detail of the bug is listed at this commit https://cgit.allseenalliance.org/gateway/gwagent.git/commit/?h=4067906a545020d9b55ea5f49fc3cf791b24e8e0

Aksel Fatih
  • 1,419
  • 18
  • 31