@@ -1,3 +1,8 @@
+2018-11-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
+
+ * sysdeps/mach/hurd/fcntl.c (__libc_fcntl): Directly return value
+ returned by __f_setlk.
+
2018-11-29 H.J. Lu <hongjiu.lu@intel.com>
Adhemerval Zanella <adhemerval.zanella@linaro.org>
@@ -141,9 +141,8 @@ __libc_fcntl (int fd, int cmd, ...)
wait = 1;
/* FALLTHROUGH */
case F_SETLK:
- result = __f_setlk (fd, fl->l_type, fl->l_whence,
- fl->l_start, fl->l_len, wait);
- break;
+ return __f_setlk (fd, fl->l_type, fl->l_whence,
+ fl->l_start, fl->l_len, wait);
default:
errno = EINVAL;
return -1;
@@ -166,9 +165,8 @@ __libc_fcntl (int fd, int cmd, ...)
wait = 1;
/* FALLTHROUGH */
case F_SETLK:
- result = __f_setlk (fd, fl->l_type, fl->l_whence,
- fl->l_start, fl->l_len, wait);
- break;
+ return __f_setlk (fd, fl->l_type, fl->l_whence,
+ fl->l_start, fl->l_len, wait);
default:
errno = EINVAL;
return -1;