]> git.ipfire.org Git - thirdparty/util-linux.git/log
thirdparty/util-linux.git
3 months agolsfd: (refactor) add has_mnt_id helper macro
Masatake YAMATO [Fri, 9 Jan 2026 05:05:44 +0000 (14:05 +0900)] 
lsfd: (refactor) add has_mnt_id helper macro

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agolib/path: add wrapers for statx(2)
Masatake YAMATO [Thu, 8 Jan 2026 21:57:45 +0000 (06:57 +0900)] 
lib/path: add wrapers for statx(2)

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agolib/path: add __format__ attr to ul_path_v?statf()
Masatake YAMATO [Fri, 9 Jan 2026 16:19:30 +0000 (01:19 +0900)] 
lib/path: add __format__ attr to ul_path_v?statf()

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agotests: (refactor) add ts_skip_config, a new helper function
Masatake YAMATO [Fri, 9 Jan 2026 03:44:00 +0000 (12:44 +0900)] 
tests: (refactor) add ts_skip_config, a new helper function

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agolib/path: (cosmetic) delete the empty line at the EOF
Masatake YAMATO [Fri, 9 Jan 2026 01:15:18 +0000 (10:15 +0900)] 
lib/path: (cosmetic) delete the empty line at the EOF

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agotests: (lsfd::mkfds-mmap-maksed-file) revise the description
Masatake YAMATO [Fri, 9 Jan 2026 02:11:53 +0000 (11:11 +0900)] 
tests: (lsfd::mkfds-mmap-maksed-file) revise the description

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
3 months agoblkpr: Call gettext() for descriptions, clean up
Karel Zak [Mon, 12 Jan 2026 15:27:23 +0000 (16:27 +0100)] 
blkpr: Call gettext() for descriptions, clean up

* Use N_() and _() macros to translate description texts.
* Avoid repeating command/flag/type names in description texts.
* Remove trailing line breaks; it's the caller's task to format
  before/after the descriptions.
* Improve coding style by starting strings at the beginning of the
  line, enhancing maintainability (80 characters limit).
* Keep "}, {" on separate lines as per our usual coding practice.

Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agoblkpr: add read-reservation command
Stefan Hajnoczi [Wed, 17 Dec 2025 18:26:07 +0000 (13:26 -0500)] 
blkpr: add read-reservation command

The new IOC_PR_READ_RESERVATION ioctl reports the current reservation on
a device. Add a command so that users can inspect the current
reservation. This is useful both for troubleshooting and for recovery
scenarios.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
3 months agoblkpr: add read-keys command
Stefan Hajnoczi [Wed, 17 Dec 2025 18:26:06 +0000 (13:26 -0500)] 
blkpr: add read-keys command

The new IOC_PR_READ_KEYS ioctl lists registered keys on a device. Add a
command so that users can inspect keys. This is useful both for
troubleshooting and for recovery scenarios.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
3 months agoblkpr: prepare for _IOR() ioctls
Stefan Hajnoczi [Wed, 17 Dec 2025 18:26:05 +0000 (13:26 -0500)] 
blkpr: prepare for _IOR() ioctls

parse_pr_command() returns the ioctl command constant for a given
command or -1 when the command is unknown. Up until now all ioctl
command constants were positive, so the following check worked:

  if (command < 0)
      err(EXIT_FAILURE, _("unknown command"));

The top two bits of ioctl command constants encode the direction (_IO,
_IOR, _IOW, _IOWR). ioctl commands defined with _IOR have negative ioctl
command constants.

Explicitly check for -1 to differentiate "unknown command" from valid
ioctls commands. Later commits will add ioctl commands that use _IOR.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
3 months agoMerge branch 'env_drop' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 13:34:30 +0000 (14:34 +0100)] 
Merge branch 'env_drop' of https://github.com/stoeckmann/util-linux

* 'env_drop' of https://github.com/stoeckmann/util-linux:
  env: ignore only invalid environment variables

3 months agoMerge branch 'lsblk-ul-startswith' of https://github.com/codefiles/util-linux
Karel Zak [Mon, 12 Jan 2026 13:17:40 +0000 (14:17 +0100)] 
Merge branch 'lsblk-ul-startswith' of https://github.com/codefiles/util-linux

* 'lsblk-ul-startswith' of https://github.com/codefiles/util-linux:
  lsblk: use ul_startswith()

3 months agoMerge branch 'typos' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 13:15:23 +0000 (14:15 +0100)] 
Merge branch 'typos' of https://github.com/stoeckmann/util-linux

* 'typos' of https://github.com/stoeckmann/util-linux:
  Fix typos in comments

3 months agoMerge branch 'login_motd_reg' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 13:14:51 +0000 (14:14 +0100)] 
Merge branch 'login_motd_reg' of https://github.com/stoeckmann/util-linux

* 'login_motd_reg' of https://github.com/stoeckmann/util-linux:
  login: only print regular files for motd

3 months agoMerge branch 'login_sig_race' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 13:13:17 +0000 (14:13 +0100)] 
Merge branch 'login_sig_race' of https://github.com/stoeckmann/util-linux

* 'login_sig_race' of https://github.com/stoeckmann/util-linux:
  login: remove signal handler before cleanup

3 months agoMerge branch 'fdisk_signal' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 12:56:19 +0000 (13:56 +0100)] 
Merge branch 'fdisk_signal' of https://github.com/stoeckmann/util-linux

* 'fdisk_signal' of https://github.com/stoeckmann/util-linux:
  fdisk: make SIGINT handler signal-safe

3 months agoMerge branch 'fix_non_kernel_style_func_braces' of https://github.com/cgoesche/util...
Karel Zak [Mon, 12 Jan 2026 12:53:24 +0000 (13:53 +0100)] 
Merge branch 'fix_non_kernel_style_func_braces' of https://github.com/cgoesche/util-linux-fork

* 'fix_non_kernel_style_func_braces' of https://github.com/cgoesche/util-linux-fork:
  style: adapt function definitions to kernel style

3 months agoMerge branch 'systemd_lock' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 12 Jan 2026 12:26:23 +0000 (13:26 +0100)] 
Merge branch 'systemd_lock' of https://github.com/stoeckmann/util-linux

* 'systemd_lock' of https://github.com/stoeckmann/util-linux:
  uuidd: use locked system user account if available

3 months agoMerge branch 'avoid-ob_refcnt-when-freethreading' of https://github.com/wdconinc...
Karel Zak [Mon, 12 Jan 2026 12:23:32 +0000 (13:23 +0100)] 
Merge branch 'avoid-ob_refcnt-when-freethreading' of https://github.com/wdconinc/util-linux

* 'avoid-ob_refcnt-when-freethreading' of https://github.com/wdconinc/util-linux:
  fix: use Py_REFCNT macro to work with free-threaded python

3 months agoMerge branch 'lslocks--Q' of https://github.com/masatake/util-linux
Karel Zak [Mon, 12 Jan 2026 12:21:32 +0000 (13:21 +0100)] 
Merge branch 'lslocks--Q' of https://github.com/masatake/util-linux

* 'lslocks--Q' of https://github.com/masatake/util-linux:
  tests: (lslocks) test -Q,--filter option
  tests: (test_mkfds::nop) new factory just printing pid
  lslocks: special-case PID for filtering (skip −1)
  lslocks: make SIZE filterable by normalizing to bytes
  lslocks: implement Q, --filter option
  lslocks: factor out code getting and setting the data from add_scols_line
  lslocks: (refactor) move proc_locks to struct lslocks
  lslocks: (refactor) move pid_locks in main to struct lslocks
  lslocks: (refactor) move "tab" file static variable to struct lslocks
  lslocks: (refactor) add struct lslocks representing the global context
  lslocks: (refactor) use global bytes in get_json_type_for_column()
  lslocks: (refactor) add a helper function refining value returned from get_lock
  lslocks: (refactor) don't use redundant callback functions
  lslocks: (refactor) specify list_head as type instead of abusing void*
  lslocks: (refactor) use separate function to initialize libscols_table
  lslocks: (refactor) remove an unused local variable
  lslocks: (refactor) use narrow variable scoping for loop counters
  lslocks: (comment) fix grammar

3 months agoMerge branch 'PR/fallocate-report-holes' of https://github.com/karelzak/util-linux...
Karel Zak [Mon, 12 Jan 2026 12:21:17 +0000 (13:21 +0100)] 
Merge branch 'PR/fallocate-report-holes' of https://github.com/karelzak/util-linux-work

* 'PR/fallocate-report-holes' of https://github.com/karelzak/util-linux-work:
  tests: convert fallocate to use subtests
  fallocate: refactor --report-holes and --dig-holes output
  fallocate: add --report-holes

3 months agolsblk: use ul_startswith()
codefiles [Sun, 11 Jan 2026 19:54:26 +0000 (14:54 -0500)] 
lsblk: use ul_startswith()

3 months agoFix typos in comments
Tobias Stoeckmann [Sat, 10 Jan 2026 22:04:24 +0000 (23:04 +0100)] 
Fix typos in comments

No functional change.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agologin: only print regular files for motd
Tobias Stoeckmann [Sat, 10 Jan 2026 21:56:45 +0000 (22:56 +0100)] 
login: only print regular files for motd

The existing code tries to only print content of non-empty files, but
does not check the target of an encountered symbolic link, which could
be even something else, e.g. a fifo. Add the missing check to the
motddir_filter function.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agologin: remove signal handler before cleanup
Tobias Stoeckmann [Sat, 10 Jan 2026 21:37:30 +0000 (22:37 +0100)] 
login: remove signal handler before cleanup

Even though alarm(0) is called, another process could still send a
SIGALRM signal to the login process, which could trigger a use after
free for a tiny amount of time.

Not able to reproduce without adding a proper sleep.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agouuidd: use locked system user account if available
Tobias Stoeckmann [Tue, 6 Jan 2026 17:14:32 +0000 (18:14 +0100)] 
uuidd: use locked system user account if available

Beginning with systemd 257, it is possible to fully lock a sysuser
account. Do so for systems with met requirements.

Older systemd versions still use unlocked accounts.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agoenv: ignore only invalid environment variables
Tobias Stoeckmann [Thu, 8 Jan 2026 20:55:10 +0000 (21:55 +0100)] 
env: ignore only invalid environment variables

Returning NULL drops the start of the currently existing linked list,
effectively removing all previously added environment variables.

Only ignore the invalid one, but keep the linked list available.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agofdisk: make SIGINT handler signal-safe
Tobias Stoeckmann [Fri, 9 Jan 2026 20:05:02 +0000 (21:05 +0100)] 
fdisk: make SIGINT handler signal-safe

Checking debug options and calling fprintf is not signal-safe.
Install a debug handler if debugging is requested and use signal-safe
output in it.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agostyle: adapt function definitions to kernel style
Christian Goeschel Ndjomouo [Fri, 9 Jan 2026 03:50:23 +0000 (22:50 -0500)] 
style: adapt function definitions to kernel style

The util-linux project preferred coding style is based on the kernel
coding-style (https://docs.kernel.org/process/coding-style.html),
which explains that opening braces should be on a line on their own
after the function signature. Therefore, let us adapt functions that
violate this convention.

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agofix: use Py_REFCNT macro to work with free-threaded python
Wouter Deconinck [Wed, 24 Dec 2025 21:49:34 +0000 (15:49 -0600)] 
fix: use Py_REFCNT macro to work with free-threaded python

3 months agoMerge branch 'fix/chrt-man-page' of https://github.com/jan-krieg/util-linux
Karel Zak [Thu, 8 Jan 2026 12:40:28 +0000 (13:40 +0100)] 
Merge branch 'fix/chrt-man-page' of https://github.com/jan-krieg/util-linux

* 'fix/chrt-man-page' of https://github.com/jan-krieg/util-linux:
  chrt: (man) fix note about --sched-period lower limit

3 months agoMerge branch 'fix/issue_3895_take2' of https://github.com/lord2y/util-linux
Karel Zak [Thu, 8 Jan 2026 12:39:44 +0000 (13:39 +0100)] 
Merge branch 'fix/issue_3895_take2' of https://github.com/lord2y/util-linux

* 'fix/issue_3895_take2' of https://github.com/lord2y/util-linux:
  tests: add regression test for repeated termreduce printing
  tests: add libsmartcols termreduce regression helper
  libsmartcols: avoid cumulative width reduction during printing

3 months agoMerge branch 'setpwnam_backup' of https://github.com/stoeckmann/util-linux
Karel Zak [Thu, 8 Jan 2026 12:37:06 +0000 (13:37 +0100)] 
Merge branch 'setpwnam_backup' of https://github.com/stoeckmann/util-linux

* 'setpwnam_backup' of https://github.com/stoeckmann/util-linux:
  login-utils: Use _PATH macros
  login-utils: Use /etc/passwd- as backup file

3 months agoMerge branch 'feat/new_tool_getpidino' of https://github.com/cgoesche/util-linux...
Karel Zak [Thu, 8 Jan 2026 12:35:43 +0000 (13:35 +0100)] 
Merge branch 'feat/new_tool_getpidino' of https://github.com/cgoesche/util-linux-fork

* 'feat/new_tool_getpidino' of https://github.com/cgoesche/util-linux-fork:
  lib: (pidfd-utils) minor correction in the ul_get_valid_pidfd_or_err() description
  tests: add getino tests
  bash-completion: add getino completions
  getino: new tool to print the unique pidfd or namespace inode number

3 months agoMerge branch 'blkid-bcachefs-fixes' of https://github.com/himikof/util-linux
Karel Zak [Thu, 8 Jan 2026 12:27:01 +0000 (13:27 +0100)] 
Merge branch 'blkid-bcachefs-fixes' of https://github.com/himikof/util-linux

* 'blkid-bcachefs-fixes' of https://github.com/himikof/util-linux:
  libblkid: (bcachefs) fix LABEL_SUB probing
  libblkid: (bcachefs) add new bcachefs_sb_member fields
  libblkid: (bcachefs) add members_v2 parsing support

3 months agolib: (pidfd-utils) minor correction in the ul_get_valid_pidfd_or_err() description
Christian Goeschel Ndjomouo [Sun, 21 Dec 2025 01:03:57 +0000 (20:03 -0500)] 
lib: (pidfd-utils) minor correction in the ul_get_valid_pidfd_or_err() description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agotests: add getino tests
Christian Goeschel Ndjomouo [Sun, 21 Dec 2025 01:06:18 +0000 (20:06 -0500)] 
tests: add getino tests

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agobash-completion: add getino completions
Christian Goeschel Ndjomouo [Sun, 21 Dec 2025 01:01:08 +0000 (20:01 -0500)] 
bash-completion: add getino completions

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agogetino: new tool to print the unique pidfd or namespace inode number
Christian Goeschel Ndjomouo [Sun, 21 Dec 2025 00:59:05 +0000 (19:59 -0500)] 
getino: new tool to print the unique pidfd or namespace inode number

Closes: #3837
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agochrt: (man) fix note about --sched-period lower limit
Jan Krieg [Thu, 8 Jan 2026 00:57:29 +0000 (01:57 +0100)] 
chrt: (man) fix note about --sched-period lower limit

Signed-off-by: Jan Krieg <jan.krieg.github796@magnonic.net>
3 months agologin-utils: Use _PATH macros
Tobias Stoeckmann [Wed, 7 Jan 2026 16:09:03 +0000 (17:09 +0100)] 
login-utils: Use _PATH macros

Avoid defining own macros which could be toggled with DEBUG.
Also add backup passwd file suffix to pathnames.h.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agologin-utils: Use /etc/passwd- as backup file
Tobias Stoeckmann [Tue, 6 Jan 2026 17:20:33 +0000 (18:20 +0100)] 
login-utils: Use /etc/passwd- as backup file

The name /etc/passwd- is used as backup file by shadow and systemd.

Let's join the group and use /etc/passwd- instead of /etc/passwd.OLD as
well. One backup file on a system is enough.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agolibblkid: (bcachefs) fix LABEL_SUB probing
Nikita Ofitserov [Sun, 4 Jan 2026 22:41:43 +0000 (01:41 +0300)] 
libblkid: (bcachefs) fix LABEL_SUB probing

It was working only for single-device filesystems and
non-hierarchical device labels before.

Signed-off-by: Nikita Ofitserov <himikof@gmail.com>
3 months agotests: add regression test for repeated termreduce printing
Alessandro Ratti [Sun, 28 Dec 2025 18:12:08 +0000 (19:12 +0100)] 
tests: add regression test for repeated termreduce printing

Add a regression test that verifies repeated printing of the same
libsmartcols table produces identical output when termreduce is used.

Before the fix, the effective output width would shrink on each print,
resulting in progressively truncated output. The test guards against
future regressions by ensuring printing remains stable across
invocations.

Signed-off-by: Alessandro Ratti <alessandro@0x65c.net>
3 months agotests: add libsmartcols termreduce regression helper
Alessandro Ratti [Sun, 28 Dec 2025 18:11:08 +0000 (19:11 +0100)] 
tests: add libsmartcols termreduce regression helper

Add a small test helper program that creates a libsmartcols table,
applies scols_table_reduce_termwidth(), and prints the table multiple
times within the same process.

The helper is used by regression tests to detect unintended cumulative
width reduction across repeated printing.

Signed-off-by: Alessandro Ratti <alessandro@0x65c.net>
3 months agolibsmartcols: avoid cumulative width reduction during printing
Alessandro Ratti [Sun, 28 Dec 2025 18:07:55 +0000 (19:07 +0100)] 
libsmartcols: avoid cumulative width reduction during printing

__scols_initialize_printing() applied scols_table_reduce_termwidth()
by mutating table->termwidth via scols_table_set_termwidth().

When printing is performed repeatedly on the same table (e.g. in
interactive applications), this causes the effective output width
to shrink on each invocation, eventually truncating output.

Introduce an internally computed effective output width and stop
modifying termwidth during printing. All layout calculations are
updated to use the derived width instead, making the printing path
idempotent.

No functional change is expected for single-shot printing.

Addresses: https://github.com/util-linux/util-linux/issues/3895
Suggested-by: Karel Zak <kzak@redhat.com>
Signed-off-by: Alessandro Ratti <alessandro@0x65c.net>
3 months agoMerge branch 'gettext_macro' of https://github.com/stoeckmann/util-linux
Karel Zak [Wed, 7 Jan 2026 10:15:37 +0000 (11:15 +0100)] 
Merge branch 'gettext_macro' of https://github.com/stoeckmann/util-linux

* 'gettext_macro' of https://github.com/stoeckmann/util-linux:
  Fix gettext macro calls

3 months agobuild-sys: (gcc) ignore -Wunused-but-set-variable for bison
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 15:43:45 +0000 (10:43 -0500)] 
build-sys: (gcc) ignore -Wunused-but-set-variable for bison

[kzak@redhat.com: - merge two Christian's patches to make it more portable]

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agozramctl: (manpage) add --bytes option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:44:29 +0000 (21:44 -0500)] 
zramctl: (manpage) add --bytes option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agosfdisk: (manpage) fix option description inconsistencies
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:42:57 +0000 (21:42 -0500)] 
sfdisk: (manpage) fix option description inconsistencies

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agosetpriv: (manpage) fix typo in option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:36:29 +0000 (21:36 -0500)] 
setpriv: (manpage) fix typo in option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoscriptlive: (manpage) add --command option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:35:17 +0000 (21:35 -0500)] 
scriptlive: (manpage) add --command option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoreadprofile: (manpage) add --no-auto option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:15:38 +0000 (21:15 -0500)] 
readprofile: (manpage) add --no-auto option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agolslogins: (manpage) fix typo in option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:11:51 +0000 (21:11 -0500)] 
lslogins: (manpage) fix typo in option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoipcrm: (manpage) add --verbose description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:09:57 +0000 (21:09 -0500)] 
ipcrm: (manpage) add --verbose description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agohwclock: (manpage) add --param-index description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 02:00:57 +0000 (21:00 -0500)] 
hwclock: (manpage) add --param-index description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoflock: (manpage) fix typo in option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 00:49:45 +0000 (19:49 -0500)] 
flock: (manpage) fix typo in option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agofdisk: (manpage) add --bytes option description
Christian Goeschel Ndjomouo [Tue, 6 Jan 2026 00:48:25 +0000 (19:48 -0500)] 
fdisk: (manpage) add --bytes option description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoci: add usage message consistency check to CI CODECHECK phase
Christian Goeschel Ndjomouo [Thu, 1 Jan 2026 00:01:57 +0000 (19:01 -0500)] 
ci: add usage message consistency check to CI CODECHECK phase

Add 'make checkmanpage' to the GitHub CI CODECHECK phase.
This ensures that all programs have a corresponding manpage
and that said manpage have a description for each long option
defined in the respective program's source code.

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agotools: verify the consistency of manpages for all programs
Christian Goeschel Ndjomouo [Wed, 31 Dec 2025 23:56:22 +0000 (18:56 -0500)] 
tools: verify the consistency of manpages for all programs

The tools/checkmanpage.sh script ensures that all programs
have a corresponding manpage as well as the integrity of
all described long options in the manpage based on the
respective programs source code.

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoFix gettext macro calls
Tobias Stoeckmann [Tue, 6 Jan 2026 19:53:12 +0000 (20:53 +0100)] 
Fix gettext macro calls

Four occurrences exist in tree in which only () was used, not _(),
which effectively means that these messages were never translated.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agolibblkid: (bcachefs) add new bcachefs_sb_member fields
Nikita Ofitserov [Sun, 4 Jan 2026 21:54:39 +0000 (00:54 +0300)] 
libblkid: (bcachefs) add new bcachefs_sb_member fields

This is now in sync with bcachefs 1.34.

Signed-off-by: Nikita Ofitserov <himikof@gmail.com>
3 months agolibblkid: (bcachefs) add members_v2 parsing support
Nikita Ofitserov [Sun, 4 Jan 2026 21:44:46 +0000 (00:44 +0300)] 
libblkid: (bcachefs) add members_v2 parsing support

Since bcachefs 1.25, in many cases bcachefs does not write members_v1 field
in the superblock, leading to UUID_SUB and FSSIZE tags missing in blkid output.
Fix this by parsing the new extendable members_v2 superblock field too.

Signed-off-by: Nikita Ofitserov <himikof@gmail.com>
3 months agomount: (man) add hint for session= on iso9660
Karel Zak [Tue, 6 Jan 2026 12:37:01 +0000 (13:37 +0100)] 
mount: (man) add hint for session= on iso9660

Fixes: https://github.com/util-linux/util-linux/issues/3940
Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agoeditorconfig: add .sh setting
Karel Zak [Tue, 6 Jan 2026 12:32:03 +0000 (13:32 +0100)] 
editorconfig: add .sh setting

Suggested-by: Masatake YAMATO <yamato@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agoMerge branch 'setpwnam' of https://github.com/stoeckmann/util-linux
Karel Zak [Tue, 6 Jan 2026 11:27:58 +0000 (12:27 +0100)] 
Merge branch 'setpwnam' of https://github.com/stoeckmann/util-linux

* 'setpwnam' of https://github.com/stoeckmann/util-linux:
  setpwnam: use getline instead of fgets
  setpwnam: only unlock when actually locked
  setpwnam: check if /etc/passwd was fully read

3 months agoAdd fuse.kio-fuse to list of pseudo file systems
Oliver Schramm [Mon, 5 Jan 2026 16:36:06 +0000 (17:36 +0100)] 
Add fuse.kio-fuse to list of pseudo file systems

Signed-off-by: Oliver Schramm <oliver.schramm97@gmail.com>
3 months agoMerge branch 'pwdutils_typo' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 5 Jan 2026 11:47:45 +0000 (12:47 +0100)] 
Merge branch 'pwdutils_typo' of https://github.com/stoeckmann/util-linux

* 'pwdutils_typo' of https://github.com/stoeckmann/util-linux:
  pwdutils: fix grammar in comments

3 months agoMerge branch 'chsh_chfn_man' of https://github.com/stoeckmann/util-linux
Karel Zak [Mon, 5 Jan 2026 11:47:11 +0000 (12:47 +0100)] 
Merge branch 'chsh_chfn_man' of https://github.com/stoeckmann/util-linux

* 'chsh_chfn_man' of https://github.com/stoeckmann/util-linux:
  login: Add UID to usage message
  login-utils/login: Sync usage with manual page
  login-utils: add UIDs to manual pages
  chsh: extend usage message

3 months agoMerge branch 'fix_coding_style' of https://github.com/cgoesche/util-linux-fork
Karel Zak [Mon, 5 Jan 2026 11:41:08 +0000 (12:41 +0100)] 
Merge branch 'fix_coding_style' of https://github.com/cgoesche/util-linux-fork

* 'fix_coding_style' of https://github.com/cgoesche/util-linux-fork:
  style: fix coding style issues

3 months agoMerge branch 'PR/pre-1970-UUIDv1' of https://github.com/t-8ch/util-linux
Karel Zak [Mon, 5 Jan 2026 11:39:54 +0000 (12:39 +0100)] 
Merge branch 'PR/pre-1970-UUIDv1' of https://github.com/t-8ch/util-linux

* 'PR/pre-1970-UUIDv1' of https://github.com/t-8ch/util-linux:
  tests: correct UUID timestamp test expectations
  libuuid: fix timestamp overflow for pre-1970 dates
  libuuid: refactor gregorian_to_unix to populate timeval directly
  libuuid: simplify gregorian-to-unix offset calculation

3 months agoMerge branch 'master' of https://github.com/higuoxing/util-linux
Karel Zak [Mon, 5 Jan 2026 11:36:35 +0000 (12:36 +0100)] 
Merge branch 'master' of https://github.com/higuoxing/util-linux

* 'master' of https://github.com/higuoxing/util-linux:
  rfkill: Output in JSON format if -J is provided.

3 months agoMerge branch 'add_annotate_opt_lscpu' of https://github.com/cgoesche/util-linux-fork
Karel Zak [Mon, 5 Jan 2026 11:34:58 +0000 (12:34 +0100)] 
Merge branch 'add_annotate_opt_lscpu' of https://github.com/cgoesche/util-linux-fork

* 'add_annotate_opt_lscpu' of https://github.com/cgoesche/util-linux-fork:
  lscpu: add --annotate info to man page
  bash-completion: (lscpu) add --annotate option
  lscpu: add column header annotations for -C and -e

3 months agoMerge branch 'fix_readprofile_mapfile_option' of https://github.com/cgoesche/util...
Karel Zak [Mon, 5 Jan 2026 11:32:13 +0000 (12:32 +0100)] 
Merge branch 'fix_readprofile_mapfile_option' of https://github.com/cgoesche/util-linux-fork

* 'fix_readprofile_mapfile_option' of https://github.com/cgoesche/util-linux-fork:
  readprofile: (manpage) fix incorrect file name in --mapfile description

3 months agoMerge branch 'lsfd--no-vsock-diag' of https://github.com/masatake/util-linux
Karel Zak [Mon, 5 Jan 2026 11:31:22 +0000 (12:31 +0100)] 
Merge branch 'lsfd--no-vsock-diag' of https://github.com/masatake/util-linux

* 'lsfd--no-vsock-diag' of https://github.com/masatake/util-linux:
  lsfd,test_mkfds: make linux/vm_sockets_diag.h optional

3 months agoMerge branch 'fix/check_long_opts_integrity_usage' of https://github.com/cgoesche...
Karel Zak [Mon, 5 Jan 2026 11:29:36 +0000 (12:29 +0100)] 
Merge branch 'fix/check_long_opts_integrity_usage' of https://github.com/cgoesche/util-linux-fork

* 'fix/check_long_opts_integrity_usage' of https://github.com/cgoesche/util-linux-fork:
  readprofile: fix memory leak related to boot_uname_r_str() in usage()
  lslogins: ignore special long options in CI CHECK
  setpriv: fix usage message inconsistency
  newgrp: provide --command info in output message
  logger: ignore libsystemd-dependent long opt in CI CHECK
  ci: add usage message consistency check to CI CHECK phase
  su-common: ignore runuser(1) specific long option in CI CHECK
  nologin: ignore well-known shell command-line options in CI CHECK
  unshare: fix inconsistency in usage message
  flock: resolve consistency issue in the usage message
  nsenter: ignore SELinux-specific long option in CI CHECK
  namei: ignore SELinux-specific long option in CI CHECK
  lsclocks: fix inconsistency in usage message
  hwclock: mark non-standard long options to ignore in CI CHECK
  tools: (get-options.sh) skip programs that do not use <struct option>
  tools: (get-options.sh) ignore long opt definitions marked with IGNORECHECK=yes
  tools: (checkusage.sh) verify the completeness of listed long options

3 months agoMerge branch 'PR/Benno-17Dec-25'
Karel Zak [Mon, 5 Jan 2026 10:19:52 +0000 (11:19 +0100)] 
Merge branch 'PR/Benno-17Dec-25'

# Conflicts:
# sys-utils/unshare.c

3 months agologin: Add UID to usage message
Tobias Stoeckmann [Sun, 4 Jan 2026 18:08:01 +0000 (19:08 +0100)] 
login: Add UID to usage message

The UID can be supplied instead of a username.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agologin-utils/login: Sync usage with manual page
Tobias Stoeckmann [Sun, 4 Jan 2026 17:39:32 +0000 (18:39 +0100)] 
login-utils/login: Sync usage with manual page

The -f option is described differently in usage and man page.
Use the usage version for better readability.

Also note in manual page that UID is allowed as argument.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agologin-utils: add UIDs to manual pages
Tobias Stoeckmann [Sun, 4 Jan 2026 14:27:04 +0000 (15:27 +0100)] 
login-utils: add UIDs to manual pages

Add information about UIDs as command line arguments to manual pages of
chfn, chsh, and su, since they accept them now.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agopwdutils: fix grammar in comments
Tobias Stoeckmann [Sun, 4 Jan 2026 17:20:58 +0000 (18:20 +0100)] 
pwdutils: fix grammar in comments

No functional change

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agosetpwnam: use getline instead of fgets
Tobias Stoeckmann [Sun, 4 Jan 2026 15:30:07 +0000 (16:30 +0100)] 
setpwnam: use getline instead of fgets

Handling long lines takes already a lot of code and if a line starts
with a NUL character, an out of boundary read occurs.

Just use getline.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agosetpwnam: only unlock when actually locked
Tobias Stoeckmann [Sun, 4 Jan 2026 15:28:39 +0000 (16:28 +0100)] 
setpwnam: only unlock when actually locked

If no lock is held, do not unlock. With glibc this is fine, but let's
not put too many expectations on library implementations.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agosetpwnam: check if /etc/passwd was fully read
Tobias Stoeckmann [Sun, 4 Jan 2026 15:26:13 +0000 (16:26 +0100)] 
setpwnam: check if /etc/passwd was fully read

An error while reading the existing /etc/passwd should be properly
handled to avoid truncation due to a bad read.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agochsh: extend usage message
Tobias Stoeckmann [Sun, 4 Jan 2026 14:26:19 +0000 (15:26 +0100)] 
chsh: extend usage message

The chsh utility accepts UIDs like chfn does, too.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
3 months agobuild(deps): bump actions/cache from 4 to 5
dependabot[bot] [Thu, 1 Jan 2026 18:05:09 +0000 (18:05 +0000)] 
build(deps): bump actions/cache from 4 to 5

Bumps [actions/cache](https://github.com/actions/cache) from 4 to 5.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
3 months agobuild(deps): bump actions/upload-artifact from 5 to 6
dependabot[bot] [Thu, 1 Jan 2026 18:05:04 +0000 (18:05 +0000)] 
build(deps): bump actions/upload-artifact from 5 to 6

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
3 months agostyle: fix coding style issues
Christian Goeschel Ndjomouo [Thu, 1 Jan 2026 04:10:57 +0000 (23:10 -0500)] 
style: fix coding style issues

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoreadprofile: fix memory leak related to boot_uname_r_str() in usage()
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 15:19:20 +0000 (10:19 -0500)] 
readprofile: fix memory leak related to boot_uname_r_str() in usage()

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agolslogins: ignore special long options in CI CHECK
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 06:03:02 +0000 (01:03 -0500)] 
lslogins: ignore special long options in CI CHECK

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agosetpriv: fix usage message inconsistency
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 05:57:09 +0000 (00:57 -0500)] 
setpriv: fix usage message inconsistency

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agonewgrp: provide --command info in output message
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 05:51:31 +0000 (00:51 -0500)] 
newgrp: provide --command info in output message

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agologger: ignore libsystemd-dependent long opt in CI CHECK
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 05:44:18 +0000 (00:44 -0500)] 
logger: ignore libsystemd-dependent long opt in CI CHECK

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agoci: add usage message consistency check to CI CHECK phase
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 05:02:46 +0000 (00:02 -0500)] 
ci: add usage message consistency check to CI CHECK phase

Add 'make checkusage' to the GitHub CI CHECK phase.
This ensures that all program's usage messages list all
long options defined in their respective source code.

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agosu-common: ignore runuser(1) specific long option in CI CHECK
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 05:00:43 +0000 (00:00 -0500)] 
su-common: ignore runuser(1) specific long option in CI CHECK

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agonologin: ignore well-known shell command-line options in CI CHECK
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 04:54:22 +0000 (23:54 -0500)] 
nologin: ignore well-known shell command-line options in CI CHECK

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agounshare: fix inconsistency in usage message
Christian Goeschel Ndjomouo [Sun, 21 Dec 2025 21:53:30 +0000 (16:53 -0500)] 
unshare: fix inconsistency in usage message

Closes: #3814
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
3 months agotests: fdisk: add regression test for missing EBR gap between logical partitions
Martin Jungblut Schreiner [Mon, 29 Dec 2025 23:46:39 +0000 (20:46 -0300)] 
tests: fdisk: add regression test for missing EBR gap between logical partitions

Add a DOS/MBR test case where the first logical partition starts at 6145
(extended start 2048). In the regressed behaviour fdisk allows the next
logical partition to start at prev_end+1, which would place its EBR
(start - 2048) inside the previous logical partition.

The expected behaviour is to require the next starting sector to be at least
prev_end + 2048 + 1 (e.g. 790528 in the testcase).

Closes issue #3925.

3 months agolibfdisk: (dos) fix logical partition start
Martin Jungblut Schreiner [Mon, 29 Dec 2025 22:52:56 +0000 (19:52 -0300)] 
libfdisk: (dos) fix logical partition start

fdisk could accept adjacent logical partitions, causing the EBR for the new
logical partition to be written inside the previous partition’s data area.
This can corrupt the EBR chain.

Fix free-sector search to keep an EBR gap (first_lba) after logical partitions.

3 months agoreadprofile: (manpage) fix incorrect file name in --mapfile description
Christian Goeschel Ndjomouo [Thu, 25 Dec 2025 16:13:30 +0000 (11:13 -0500)] 
readprofile: (manpage) fix incorrect file name in --mapfile description

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>