Fix typecasting error on 64bit build 12/66212/2 accepted/tizen/common/20160418.141650 accepted/tizen/ivi/20160418.083345 accepted/tizen/mobile/20160418.083458 accepted/tizen/tv/20160418.083329 accepted/tizen/wearable/20160418.083337 submit/tizen/20160418.022016
authorWonnam Jang <wn.jang@samsung.com>
Mon, 18 Apr 2016 02:04:04 +0000 (11:04 +0900)
committerWonnam Jang <wn.jang@samsung.com>
Mon, 18 Apr 2016 02:06:45 +0000 (11:06 +0900)
Change-Id: Ib997ca5d0f6a0150834217ca9cfc8176fad1498e
Signed-off-by: Wonnam Jang <wn.jang@samsung.com>
CMakeLists.txt
server/sttd_server.c [changed mode: 0755->0644]

index dba8462..0f20fce 100644 (file)
@@ -26,6 +26,7 @@ SET(EXEC_PREFIX "${PREFIX}")
 SET(VERSION 0.2.54)
 
 ADD_DEFINITIONS("-DSTT_LIBDIR=\"${LIBDIR}\"")
+ADD_DEFINITIONS("-Werror")
 
 ## Include common directory ##
 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/common")
old mode 100755 (executable)
new mode 100644 (file)
index b36f8a2..c1b9b1c
@@ -984,7 +984,8 @@ Eina_Bool __stop_by_recording_timeout(void *data)
 
 void __sttd_server_recorder_start(void* data)
 {
-       int uid = (int)data;
+       intptr_t puid = (intptr_t)data;
+       int uid = (int)puid;
        int current_uid = stt_client_get_current_recognition();
 
        if (uid != current_uid) {
@@ -1093,7 +1094,8 @@ int sttd_server_start(int uid, const char* lang, const char* recognition_type, i
        /* 2. Request wav play */
        if (NULL != sound) {
                int id = 0;
-               ret = wav_player_start(sound, SOUND_TYPE_MEDIA, __sttd_start_sound_completed_cb, (void*)uid, &id);
+               intptr_t puid = (intptr_t)uid;
+               ret = wav_player_start(sound, SOUND_TYPE_MEDIA, __sttd_start_sound_completed_cb, (void*)puid, &id);
                if (WAV_PLAYER_ERROR_NONE != ret) {
                        SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to play wav");
                        is_sound_done = true;
@@ -1184,7 +1186,8 @@ Eina_Bool __time_out_for_processing(void *data)
 
 void __sttd_server_engine_stop(void* data)
 {
-       int uid = (int)data;
+       intptr_t puid = (intptr_t)data;
+       int uid = (int)puid;
        /* change uid state */
        sttd_client_set_state(uid, APP_STATE_PROCESSING);
 
@@ -1263,7 +1266,8 @@ int sttd_server_stop(int uid)
        /* 2. Request wav play */
        if (NULL != sound) {
                int id = 0;
-               ret = wav_player_start(sound, SOUND_TYPE_MEDIA, __sttd_stop_sound_completed_cb, (void*)uid, &id);
+               intptr_t puid = (intptr_t)uid;
+               ret = wav_player_start(sound, SOUND_TYPE_MEDIA, __sttd_stop_sound_completed_cb, (void*)puid, &id);
                if (WAV_PLAYER_ERROR_NONE != ret) {
                        SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to play wav");
                } else {