}
app_state_e temp_app_state;
- sttd_client_get_state(uid, &temp_app_state);
+ if (0 != sttd_client_get_state(uid, &temp_app_state)) {
+ SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] uid is NOT valid ");
+ return;
+ }
if (APP_STATE_READY != temp_app_state && 0 != stt_client_get_current_recognition()) {
/* Notify uid state change */
sttdc_send_set_state(uid, APP_STATE_RECORDING);
return ret;
}
- sttd_client_get_state(uid, &temp_app_state);
+ if (0 != sttd_client_get_state(uid, &temp_app_state)) {
+ SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] uid is NOT valid");
+ return STTD_ERROR_INVALID_PARAMETER;
+ }
if (APP_STATE_READY != temp_app_state && 0 != stt_client_get_current_recognition()) {
/* Notify uid state change */
sttdc_send_set_state(uid, APP_STATE_RECORDING);