From nobody Mon Dec 13 01:00:59 2021 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4FA8E18D37F0; Mon, 13 Dec 2021 01:01:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JC3975Ytsz3nyD; Mon, 13 Dec 2021 01:00:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 97A853348; Mon, 13 Dec 2021 01:00:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1BD10x4k010257; Mon, 13 Dec 2021 01:00:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1BD10xJV010256; Mon, 13 Dec 2021 01:00:59 GMT (envelope-from git) Date: Mon, 13 Dec 2021 01:00:59 GMT Message-Id: <202112130100.1BD10xJV010256@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: ba6f5ed72edd - stable/13 - fcntl(2): be more precise about third arg type List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: ba6f5ed72edd9c61ff313e8fb11f29ddcd438a35 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1639357260; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Bn2o0QYoklWUnaX0Y1OTCQwXJMLBiT0SB74GEAvkzhA=; b=kTviHQbelUeNBLo+hTLUnR2txzYcK/yCmojmEdnsDq+Q6gesP1SkKXGTq+4uEoqPnz5AbG UgM6ZSz9UQuWCuTrHnKvh1mWTQNkw4RPi4FQUmFnUVQqHT6D7FRfSSILecfrpcP35Vjrxl rGFMFXMDIfKZfZjz4GCseO/BY9z0TYIyFP0lxqHzk56wsfKyF5NKiajSuP6ii62GMuVRlr kqsa6v9MqumW03enUrzyWgUx6NctdnOPt8RIIhJhHlnq6lfyTaEJG0/w+LTgDIc2YH/x9f JmFPtNrKwo3y1SMNj18vbJZZmK/9NSh0UjgHjiaKrXeuFqGDgiX0JasWGYzYzA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1639357260; a=rsa-sha256; cv=none; b=Z3t5axKAlnXq51fma6yRkMdNhp3mnKU4dUEmYji9PsDmG50frZq7aj4N4rp2VdXcBebaQY UZnLbS1ZtYlYX37izTLBU6y4NnCEO2k6VeZOkq7jnhbruGjTlNfuL4/48KLXKAvHekhgM+ N0VLhDVWRMLjRlsPBYOYtc84uu1O4j1ntl/uqu0BA1C5PNQpQUTGh9DY7/BTrToFL9eUVH LGW7wpEGLNrr3t1+JH38E6jkLAhA9yFwQjd5nCtNTA2u6EKAlAWwmvkpyLZOTaJs++2wzu QJdf+Kv8I/bwhOg+4YN/6gdVq1CyOU5VQEDjS2biDEtYX4G3MiusWEG6OUbypA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=ba6f5ed72edd9c61ff313e8fb11f29ddcd438a35 commit ba6f5ed72edd9c61ff313e8fb11f29ddcd438a35 Author: Konstantin Belousov AuthorDate: 2021-12-06 20:14:25 +0000 Commit: Konstantin Belousov CommitDate: 2021-12-13 00:58:22 +0000 fcntl(2): be more precise about third arg type (cherry picked from commit 97722455cce4f8398f6411eaaa80d595dcb5fb3c) --- lib/libc/sys/fcntl.2 | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/libc/sys/fcntl.2 b/lib/libc/sys/fcntl.2 index c0a13ee6df18..d6d48f7a4797 100644 --- a/lib/libc/sys/fcntl.2 +++ b/lib/libc/sys/fcntl.2 @@ -53,7 +53,11 @@ Depending on the value of .Fa cmd , .Fn fcntl can take an additional third argument -.Fa "long arg" . +.Fa arg . +Unless otherwise noted below for a specific operation, +.Fa arg +has type +.Vt int . .Bl -tag -width F_DUP2FD_CLOEXEC .It Dv F_DUPFD Return a new descriptor as follows: @@ -286,7 +290,7 @@ and will fail and return .Dv EINVAL . .Pp -Several commands are available for doing advisory file locking; +Several operations are available for doing advisory file locking; they all operate on the following structure: .Bd -literal struct flock { @@ -298,6 +302,10 @@ struct flock { int l_sysid; /* remote system id or zero for local */ }; .Ed +These advisory file locking operations take a pointer to +.Vt struct flock +as the third argument +.Fa arg . The commands available for advisory record locking are as follows: .Bl -tag -width F_SETLKWX .It Dv F_GETLK