[SSM] Cleanup JNI dead code and add NDEBUG definition
authorjk13 <jihyeok13.kim@samsung.com>
Fri, 6 Feb 2015 05:38:37 +0000 (14:38 +0900)
committerUze Choi <uzchoi@samsung.com>
Fri, 6 Feb 2015 08:44:31 +0000 (08:44 +0000)
1. Cleanup JNI dead code
2. Add NDEBUG definition to SCONS script to prevent crash
   when assert

Change-Id: Ia4dc46548ce3bb0c9b4b28776e6c5f328444ab1a
Signed-off-by: jk13 <jihyeok13.kim@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/314
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Uze Choi <uzchoi@samsung.com>
service/soft-sensor-manager/SConscript
service/soft-sensor-manager/SSMCore/src/SSMInterface/SSMCore_JNI.cpp

index 0044431..6e12a76 100644 (file)
@@ -20,7 +20,7 @@ if target_os == 'arduino':
 # Build flags
 ######################################################################
 if target_os not in ['windows', 'winrt']:
-       soft_sensor_manager_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-DLINUX'])
+       soft_sensor_manager_env.AppendUnique(CXXFLAGS = ['-std=c++0x', '-Wall', '-DLINUX', '-DNDEBUG'])
        if target_os != 'android':
                soft_sensor_manager_env.AppendUnique(LIBS = ['pthread'])
 
index 5c65d65..a8351c5 100644 (file)
@@ -109,8 +109,6 @@ class QueryEngineEventReceiver
                 env->GetMethodID(g_ClassQueryEngineEvent, "OnQueryEngineEvent",
                                  "(ILorg/iotivity/service/ssm/DataReader;)V");
 
-            jclass callbackObject = env->GetObjectClass(m_objQueryEngineEvent);
-
             jmethodID cid_DataReader = env->GetMethodID(g_ClassDataReader, "<init>", "(I)V");
 
             if (cid_DataReader == NULL)