On 02/19/2014 06:53 PM, Gilles Chanteperdrix wrote:
On 02/19/2014 06:49 PM, git repository hosting wrote:
diff --git a/kernel/cobalt/posix/internal.h
b/kernel/cobalt/posix/internal.h
index 915871f..2b53073 100644
--- a/kernel/cobalt/posix/internal.h
+++ b/kernel/cobalt/posix/internal.h
@@ -64,6 +64,12 @@ static inline struct cobalt_kqueues
*cobalt_kqueues(int pshared)
      return &ppd->kqueues;
  }

+static inline xnhandle_t cobalt_get_handle_from_user(xnhandle_t *u_h)
+{
+    xnhandle_t handle;
+    return __xn_get_user(handle, u_h) ? 0 : handle;
+}
+

Should not we return (xnhandle_t)-1 here ? Is not 0 a valid handle?



No.

--
Philippe.

_______________________________________________
Xenomai mailing list
[email protected]
http://www.xenomai.org/mailman/listinfo/xenomai

Reply via email to