VOP_PATHCONF(9)
π VOP_PATHCONF π
okay bestie, so this is a page from the Kernel Developer's Manual β section 9, kernel-adjacent, very much for the devs poking around in the vnode layer π β and it's called VOP_PATHCONF. Sit down, grab a boba, we're getting into it. π§β¨
β¨ NAME β¨
VOP_PATHCONF β return POSIX pathconf information
πΈ SYNOPSIS πΈ
#include <sys/param.h>
#include <sys/vnode.h>
#include <sys/unistd.h>
int
VOP_PATHCONF(struct vnode *vp, int name, long *retval);
π¦ DESCRIPTION π¦
So basically, the arguments are giving:
vpβ the vnode we wanna get info about πnameβ the type of information to return, like the category, the vibe of the questionretvalβ the place to return the information, i.e. where the answer gets dropped off π
And the value of name is literally what decides what comes back:
_PC_LINK_MAXβ the maximum number of links to a file π_PC_NAME_MAXβ the maximum number of bytes in a file name π_PC_PATH_MAXβ the maximum number of bytes in a pathname π€οΈ_PC_PIPE_BUFβ the maximum number of bytes which will be written atomically to a pipe π°_PC_CHOWN_RESTRICTEDβ returns1if appropriate privileges are required for thechown(2)system call, otherwise0π_PC_NO_TRUNCβ returns1if file names longer thanKERN_NAME_MAXare truncated βοΈ
π RETURN VALUES π
If name is recognized, *retval gets set to the specified value and zero is returned. If it's not recognized? EINVAL. no in-between, that's just how she goes π
π SEE ALSO π
π AUTHORS π
This manual page was written by Doug Rabson. iconic of him, honestly π«Ά
okay that's the whole thing, you ate that, go forth and pathconf responsibly π
Debian β’ July 21, 2019 β that's the version-and-date sign-off bestie, mwah πβ¨
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (c) 1996 Doug Rabson
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms