changeset 241:93bbb462fa84

8133673: sqe tests ListenerNegative and ConfigurePinNegative fail due to thrown IOException OTHER THAN DeviceNotFoundException Summary: Correct return error code Reviewed-by: alkonsta
author snazarki
date Fri, 14 Aug 2015 20:23:37 +0300
parents 810d9321e203
children 5b82c52de3c7
files src/share/linux/native/com/oracle/dio/gpio/gpio.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/linux/native/com/oracle/dio/gpio/gpio.c	Fri Aug 14 18:42:21 2015 +0300
+++ b/src/share/linux/native/com/oracle/dio/gpio/gpio.c	Fri Aug 14 20:23:37 2015 +0300
@@ -529,10 +529,10 @@
 
     if(-1 == directionFD  && errno == ENOENT) {
         //file does not exist, need to enable GPIOPin
-        if (enable_gpio_pin(pin) != JAVACALL_DIO_OK) {
+        if ((res = enable_gpio_pin(pin)) != JAVACALL_DIO_OK) {
             unlock_pin_list();
             // error is printed at enable_gpio_pin
-            return JAVACALL_DIO_FAIL;
+            return res;
         }else{
             count = 0;
             /*