From patchwork Wed Dec 19 01:19:19 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 1015780 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-98563-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ens-lyon.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="fmDFDjES"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43KH9c0VDbz9sCQ for ; Wed, 19 Dec 2018 12:19:31 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; q=dns; s=default; b=pys Jyy/fasWae9MSWhs+mks0dXxNml4WatScGUa13pftGPKEGENWlYPbrIcbsb/j8m2 7nji6Xfv/SYSo1gqCyYK7UnXNjxW+0v8bPzZ/ZyHxuovdP/g5C5W9Ig3j3Y7s0RV DOAubzLpzRMHXP7Q3/08lsuKVYO33ayEvuhwNr4c= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; s=default; bh=MPU64dFnF 9/VQhE/92D9u0ziqPQ=; b=fmDFDjESU7OdTfZX3KCRkGK3VzGYjjnvkiLYx79Hq GhNguNpZgOdnKKgKeOmzlVn1T0+capxYcPz0F9sTMHZrw0KL0qcw7BsyVacnjUyG LSx2DWActzuFi4j+b/flfAEMmv8klYUvHOuKHHm3KOD7ZJw+WRyRJ57ooLEEzI75 jk= Received: (qmail 75448 invoked by alias); 19 Dec 2018 01:19:26 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 75088 invoked by uid 89); 19 Dec 2018 01:19:25 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=sk:samuel., sk:samuel, HX-Envelope-From:sk:samuel., H*r:181 X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault , commit-hurd@gnu.org Subject: [hurd,commited] hurd: Fix 64bit fcntl lock implementation Date: Wed, 19 Dec 2018 02:19:19 +0100 Message-Id: <20181219011919.15352-1-samuel.thibault@ens-lyon.org> MIME-Version: 1.0 * sysdeps/mach/hurd/fcntl.c (__libc_fcntl): Test against 64bit `cmd' values in the 64bit value cases. --- ChangeLog | 5 +++++ sysdeps/mach/hurd/fcntl.c | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2945be5253..2ea7440b5a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2018-12-18 Samuel Thibault + + * sysdeps/mach/hurd/fcntl.c (__libc_fcntl): Test against 64bit `cmd' + values in the 64bit value cases. + 2018-12-18 Albert ARIBAUD * include/time.h diff --git a/sysdeps/mach/hurd/fcntl.c b/sysdeps/mach/hurd/fcntl.c index f7f9abce03..663dcb0090 100644 --- a/sysdeps/mach/hurd/fcntl.c +++ b/sysdeps/mach/hurd/fcntl.c @@ -158,13 +158,13 @@ __libc_fcntl (int fd, int cmd, ...) va_end (ap); switch (cmd) { - case F_GETLK: + case F_GETLK64: errno = ENOSYS; return -1; - case F_SETLKW: + case F_SETLKW64: wait = 1; /* FALLTHROUGH */ - case F_SETLK: + case F_SETLK64: return __f_setlk (fd, fl->l_type, fl->l_whence, fl->l_start, fl->l_len, wait); default: