sensor: hal: tw2: fix coding rule violations 56/149456/1 accepted/tizen/4.0/unified/20170913.153407 submit/tizen/20170912.122922 submit/tizen_4.0/20170912.122922
authorkibak.yoon <kibak.yoon@samsung.com>
Tue, 12 Sep 2017 02:26:28 +0000 (11:26 +0900)
committerkibak.yoon <kibak.yoon@samsung.com>
Tue, 12 Sep 2017 08:49:22 +0000 (17:49 +0900)
Change-Id: I6695b7d74efb6761d1208a649d8cd79640a4fa2f
Signed-off-by: kibak.yoon <kibak.yoon@samsung.com>
src/gyro/gyro_device.cpp
src/hrm/hrm_device.cpp
src/pressure/pressure_device.cpp
src/sensor_log.h
src/util.cpp

index 70ed0e3721103c235072bc6118826a6185e6d9bd..c5ee4592a23b9a360458a32a41defbcca33e6939 100644 (file)
@@ -158,7 +158,7 @@ bool gyro_device::set_interval(uint32_t id, unsigned long val)
 
 bool gyro_device::update_value_input_event(void)
 {
-       int gyro_raw[3] = {0,};
+       int gyro_raw[3] = {0, };
        bool x, y, z;
        int read_input_cnt = 0;
        const int INPUT_MAX_BEFORE_SYN = 10;
index 9f3d9d4571739ecac758ac31c6ef9b9cd909e053..d00c1adb84c9fa6611e06c433ee8f5ad60e79185 100644 (file)
@@ -166,7 +166,7 @@ bool hrm_device::update_value_input_event(void)
 {
        const float SNR_SIG_FIGS = 10000.0f;
        const int HR_MAX = 300;
-       int hrm_raw[4] = {0,};
+       int hrm_raw[4] = {0, };
        unsigned long long fired_time = 0;
        int read_input_cnt = 0;
        const int INPUT_MAX_BEFORE_SYN = 10;
index 7153f99c327b87f3346743cb191d343940dc3914..c98c084ff3dd18e06e2773fcc77e271b0482cd33 100644 (file)
@@ -162,7 +162,7 @@ bool pressure_device::set_interval(uint32_t id, unsigned long val)
 
 bool pressure_device::update_value_input_event(void)
 {
-       int pressure_raw[3] = {0,};
+       int pressure_raw[3] = {0, };
        bool pressure = false;
        bool sea_level = false;
        bool temperature = false;
@@ -177,7 +177,7 @@ bool pressure_device::update_value_input_event(void)
        while ((syn == false) && (read_input_cnt < INPUT_MAX_BEFORE_SYN)) {
                int len = read(m_node_handle, &pressure_event, sizeof(pressure_event));
                if (len != sizeof(pressure_event)) {
-                       _E("pressure_file read fail, read_len = %d\n",len);
+                       _E("pressure_file read fail, read_len = %d\n", len);
                        return false;
                }
 
index 496786ea2b4f45c5ac92db5c878a8e7eb599c4f0..8ac5abb22f5dccf828a45e08a896a416d0b8f5e8 100644 (file)
 #endif
 #define LOG_TAG        "SENSOR"
 
-#define LOG_DUMP(fp, fmt, arg...) do { if (fp) fprintf(fp, fmt, ##arg); else _E(fmt, ##arg); } while(0)
+#define LOG_DUMP(fp, fmt, arg...) do { if (fp) fprintf(fp, fmt, ##arg); else _E(fmt, ##arg); } while (0)
 
 #ifdef _DEBUG
 #define DBG SLOGD
 #else
-#define DBG(...) do{} while(0)
+#define DBG(...) do { } while (0)
 #endif
 
 #define ERR SLOGE
index 07532b8da516254dc437f4faebe9ac9e9999fde2..1692d4411463cb13d974312bfa0993dc5d60aba1 100644 (file)
@@ -153,7 +153,6 @@ static bool get_input_method(const string &key, int &method, string &device_num)
        bool find = false;
 
        for (int i = 0; i < input_info_len; ++i) {
-
                prefix_size = input_info[i].prefix.size();
 
                dir = opendir(input_info[i].dir_path.c_str());