Commit 010f30da authored by Jay Sharma's avatar Jay Sharma Committed by Madan Lanka

[Easy-Setup][IOT-1016] Fixed Jira issue.

Change-Id: I2690cd69ad35fd95759cdc66361e45c84b42a7f4
Signed-off-by: default avatarJay Sharma <jay.sharma@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/6255Tested-by: default avatarjenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: default avatarMadan Lanka <lanka.madan@samsung.com>
parent 015374be
......@@ -284,11 +284,13 @@ public class MainActivity extends Activity {
"0.0.0.0", // bind to all available interfaces
0,
QualityOfService.LOW, filePath + OIC_CLIENT_JSON_DB_FILE);
OcPlatform.Configure(cfg);
try {
/*
* Initialize DataBase
*/
OcPlatform.Configure(cfg);
String sqlDbPath = getFilesDir().getAbsolutePath().replace("files", "databases") +
File.separator;
File file = new File(sqlDbPath);
......@@ -304,6 +306,15 @@ public class MainActivity extends Activity {
} catch (OcException e) {
logMessage(TAG + "provisionInit error: " + e.getMessage());
Log.e(TAG, e.getMessage());
} catch (UnsatisfiedLinkError e) {
// Note : Easy setup is built with SECURED = 0, but user still selects Security feature
// while running the Mediator App it couldn't find "libocprovision.so".
// As per the programmer guide, security feature should be invoked only if build is done with SECURED = 1.
Log.e(TAG, " Easy setup is built with secured = 0, but executed with security feature");
Toast.makeText(this,"Security is not enabled [Easy setup is built with SECURED = 0]",
Toast.LENGTH_LONG).show();
mEnableSecurity.setChecked(false);
}
}
/**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment