-Correcting the position of the starting brace in the if condition.
-Adding error handling condition in the common test folder for unregistering the event.
-Changes have been made as per reviews in previous patches.
Change-Id: I407bb6a22ddf0756aed2e7c3649a1c3490a7ba28
m_quat_gaming_rv = euler2quat(euler_gaming_rv);
- if (is_initialized(m_state_new))
- {
+ if (is_initialized(m_state_new)) {
m_state_error.m_vec[0] = euler_error.m_ang.m_vec[0];
m_state_error.m_vec[1] = euler_error.m_ang.m_vec[1];
m_state_error.m_vec[2] = euler_error.m_ang.m_vec[2];
g_main_loop_run(mainloop);
g_main_loop_unref(mainloop);
- sensord_unregister_event(handle, event);
+ result = sensord_unregister_event(handle, event);
+
+ if (result < 0) {
+ printf("Error\n\n");
+ return -1;
+ }
+
stop_handle = sensord_stop(handle);
if (stop_handle < 0) {