gpio: fix the bug that interrupted callback is not called 61/154561/1 accepted/tizen/4.0/unified/20171010.163325 submit/tizen_4.0/20171010.131911 tizen_4.0.IoT.p1_release
authorkibak.yoon <kibak.yoon@samsung.com>
Tue, 10 Oct 2017 11:28:43 +0000 (20:28 +0900)
committerKibak Yoon <kibak.yoon@samsung.com>
Tue, 10 Oct 2017 12:20:56 +0000 (12:20 +0000)
- because "link" is just only the temporary iterator, it should be changed to
  interrupt_cb_in_list pointer.

Change-Id: Ifa0f39c6e963f022fefec80f4fc1f64ffc8ad805
Signed-off-by: kibak.yoon <kibak.yoon@samsung.com>
src/peripheral_gpio.c
src/peripheral_io.xml

index 93d1231..a93bd54 100644 (file)
@@ -95,7 +95,7 @@ static int __interrupted_cb_info_list_append(peripheral_gpio_h gpio, peripheral_
                        return PERIPHERAL_ERROR_OUT_OF_MEMORY;
                }
 
-               link = g_list_append(link, cb_info);
+               interrupted_cb_info_list = g_list_append(interrupted_cb_info_list, cb_info);
        }
 
        cb_info->handle = gpio;
index 9b556d6..466efac 100644 (file)
                        <arg type="u" name="handle" direction="in"/>
                        <arg type="i" name="result" direction="out"/>
                </method>
-               <signal name='InterruptedCb'>
-                       <arg type='i' name='pin'/>
-                       <arg type='i' name='value'/>
-                       <arg type='t' name='timestamp'/>
+               <signal name="InterruptedCb">
+                       <arg type="i" name="pin"/>
+                       <arg type="i" name="value"/>
+                       <arg type="t" name="timestamp"/>
                </signal>
                <method name="Read">
                        <arg type="u" name="handle" direction="in"/>