]> git.ipfire.org Git - thirdparty/util-linux.git/log
thirdparty/util-linux.git
2 weeks agobuild-sys: update release dates stable/v2.41 v2.41.3
Karel Zak [Mon, 15 Dec 2025 12:50:01 +0000 (13:50 +0100)] 
build-sys: update release dates

Signed-off-by: Karel Zak <kzak@redhat.com>
2 weeks agodocs: add v2.41.3-ReleaseNotes
Karel Zak [Mon, 15 Dec 2025 12:49:45 +0000 (13:49 +0100)] 
docs: add v2.41.3-ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
2 weeks agopo: update sr.po (from translationproject.org)
Мирослав Николић [Mon, 15 Dec 2025 12:38:51 +0000 (13:38 +0100)] 
po: update sr.po (from translationproject.org)

2 weeks agopo-man: merge changes
Karel Zak [Mon, 15 Dec 2025 12:38:48 +0000 (13:38 +0100)] 
po-man: merge changes

2 weeks agopo-man: update sr.po (from translationproject.org)
Мирослав Николић [Mon, 15 Dec 2025 12:38:43 +0000 (13:38 +0100)] 
po-man: update sr.po (from translationproject.org)

2 weeks agoFix memory leak in setpwnam()
yao zhang [Thu, 11 Dec 2025 11:20:58 +0000 (19:20 +0800)] 
Fix memory leak in setpwnam()

Add memeory release for tmpname upon successful return.

(cherry picked from commit 9ac5db2c5b7b8bde467448968c77a289b4ed1465)

3 weeks agolscpu: use maximum CPU speed from DMI, avoid duplicate version string
Karel Zak [Thu, 21 Aug 2025 09:35:17 +0000 (11:35 +0200)] 
lscpu: use maximum CPU speed from DMI, avoid duplicate version string

* Read maximum CPU speed from DMI
* Don't use max speed if nonsensical
* Avoid appending "CPU @ speed" to the version string if it's already included.
  (This is a code robustness improvement as DMI is currently read for ARMs only,
   and the issue was detected on Intel.)

Fixes: https://github.com/util-linux/util-linux/commit/a772d7c493afcec32f0123fc947013f74db6e45d
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c332544d215ccb466a64a441eb5a421b9fe8cdfd)

3 weeks agolsfd: fix memory leak related to stat_error_class
Masatake YAMATO [Sat, 29 Nov 2025 19:10:46 +0000 (04:10 +0900)] 
lsfd: fix memory leak related to stat_error_class

Memory objects pointed by the name member of a file object allocate as
an instance of stat_error_class are leaked.

I intrdouced this bug in a125e2eea7cea4d0bac1404c2e1b1d65d11cc10c.  In
the commit, I arranged the class hierarchy.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
(cherry picked from commit 3ce751c0347de472ac1dcdd58e06a21759f1ad78)

3 weeks agolsfd: (bugfix) use PRIu32 for prining lport of netlink socket
Masatake YAMATO [Sat, 8 Nov 2025 02:42:31 +0000 (11:42 +0900)] 
lsfd: (bugfix) use PRIu32 for prining lport of netlink socket

Fixes #3849

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
(cherry picked from commit 5bbe47432f98a7e391da04157af9906832058ef7)

3 weeks agoeject: fix const qualifier warning in read_speed
Karel Zak [Thu, 27 Nov 2025 15:50:19 +0000 (16:50 +0100)] 
eject: fix const qualifier warning in read_speed

Fix const qualifier discarded warning in read_speed().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strrchr() function returns a pointer into a const string, so the
receiving variable must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit cc1f2ac99b99eede36a58cf115a56bdfbc977e52)

3 weeks agopartx: fix const qualifier warning in get_max_partno
Karel Zak [Thu, 27 Nov 2025 15:48:53 +0000 (16:48 +0100)] 
partx: fix const qualifier warning in get_max_partno

Fix const qualifier discarded warning in get_max_partno().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strrchr() function returns a pointer into a const string, so the
receiving variable must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 4c94ce5d05d97420df7a512bbbaee8c4017414ae)

3 weeks agoenosys: fix const qualifier warning in parse_block
Karel Zak [Thu, 27 Nov 2025 15:47:46 +0000 (16:47 +0100)] 
enosys: fix const qualifier warning in parse_block

Fix const qualifier discarded warning in parse_block().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strchr() function returns a pointer into a const string, so the
receiving variable must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 70379d240dcf975d140160bb4c14cf1b3fe70bcc)

3 weeks agowhereis: fix const qualifier warnings for C23
Karel Zak [Thu, 27 Nov 2025 15:46:22 +0000 (16:46 +0100)] 
whereis: fix const qualifier warnings for C23

Fix const qualifier discarded warnings in dirlist_add_subdir() and
lookup() functions. These warnings are reported by gcc 15 which
defaults to the C23 standard.

The strchr() and strrchr() functions return pointers into const strings,
so the receiving variables must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 01018b74163f9122c75179a7c991b0aa0f8c603c)

3 weeks agonamei: fix const qualifier warning in readlink_to_namei
Karel Zak [Thu, 27 Nov 2025 15:44:47 +0000 (16:44 +0100)] 
namei: fix const qualifier warning in readlink_to_namei

Fix const qualifier discarded warning in readlink_to_namei().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strrchr() function returns a pointer into a const string, so the
receiving variable must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit e318417f00982bf496fd2359853b07ada3e3c544)

3 weeks agologger: fix const qualifier warnings for C23
Karel Zak [Thu, 27 Nov 2025 15:43:38 +0000 (16:43 +0100)] 
logger: fix const qualifier warnings for C23

Fix const qualifier discarded warnings in valid_structured_data_param()
and valid_structured_data_id() functions. These warnings are reported by
gcc 15 which defaults to the C23 standard.

The strchr() and strstr() functions return pointers into const strings,
so the receiving variables must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 22c3b959ef381b35a55ed00cf6acd2507b461d4b)

3 weeks agolsfd: fix const qualifier warning in strnrstr
Karel Zak [Thu, 27 Nov 2025 15:38:18 +0000 (16:38 +0100)] 
lsfd: fix const qualifier warning in strnrstr

Fix const qualifier discarded warning in strnrstr().
This warning is reported by gcc 15 which defaults to the C23 standard.

The function returns a non-const pointer into the haystack parameter,
and callers modify the string through that pointer. Therefore, the
haystack parameter should be char * rather than const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 935f2ab21add95059a92208f69ef578708307481)

3 weeks agolsfd: fix const qualifier warning in new_counter_spec
Karel Zak [Thu, 27 Nov 2025 15:35:56 +0000 (16:35 +0100)] 
lsfd: fix const qualifier warning in new_counter_spec

Fix const qualifier discarded warning in new_counter_spec().
This warning is reported by gcc 15 which defaults to the C23 standard.

The function modifies the input string by inserting a null terminator
to split it into name and expression parts, so the parameter should
be char * rather than const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 014d2779afb4118d7117442eeed562e2c7b7594f)

3 weeks agodmesg: fix const qualifier warnings in parse_callerid
Karel Zak [Thu, 27 Nov 2025 15:33:04 +0000 (16:33 +0100)] 
dmesg: fix const qualifier warnings in parse_callerid

Fix const qualifier discarded warnings in parse_callerid().
These warnings are reported by gcc 15 which defaults to the C23 standard.

The strchr() and strstr() functions return pointers into const strings,
so the receiving variables must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 40e6850d2b2ba2492d5f3e75656cb9bcce2806bb)

3 weeks agolibblkid: fix const qualifier warning in blkid_parse_tag_string
Karel Zak [Thu, 27 Nov 2025 15:28:41 +0000 (16:28 +0100)] 
libblkid: fix const qualifier warning in blkid_parse_tag_string

Fix const qualifier discarded warning in blkid_parse_tag_string().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strchr() function returns a pointer into a const string, so
introduce a separate 'eq' variable to hold this const pointer for
finding the '=' separator. Also move the 'cp' variable declaration
into the block where it's actually used for quote handling.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c45442ef125270d0ab2cb539747ccaf737d60d37)

3 weeks agolibmount: fix const qualifier warning in mnt_parse_mountinfo_line
Karel Zak [Thu, 27 Nov 2025 15:24:11 +0000 (16:24 +0100)] 
libmount: fix const qualifier warning in mnt_parse_mountinfo_line

Fix const qualifier discarded warning in mnt_parse_mountinfo_line().
This warning is reported by gcc 15 which defaults to the C23 standard.

The strstr() function returns a pointer into a const string, so
introduce a separate 'sep' variable to hold this const pointer,
keeping 'p' for non-const unmangle() results that need to be freed.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 530bf5c5b071753e149699c638ad1820daf5c205)

3 weeks agolibmount: fix const qualifier warnings for C23
Karel Zak [Thu, 27 Nov 2025 14:45:55 +0000 (15:45 +0100)] 
libmount: fix const qualifier warnings for C23

Fix const qualifier discarded warnings in optlist_add_flags(),
mnt_opt_value_with(), and mnt_optstr_apply_flags() functions.
These warnings are reported by gcc 15 which defaults to the C23 standard.

The strchr() and strstr() functions return pointers into const strings,
so the receiving variables must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c0c79c41527365ca7de30c75daaa018ea01fff97)

3 weeks agolsns: fix const qualifier warnings for C23
Karel Zak [Thu, 27 Nov 2025 14:41:21 +0000 (15:41 +0100)] 
lsns: fix const qualifier warnings for C23

Fix const qualifier discarded warnings in read_persistent_namespaces()
and is_path_included() functions. These warnings are reported by gcc 15
which defaults to the C23 standard.

The strchr() and strstr() functions return pointers into const strings,
so the receiving variables must be declared as const char *.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit dbe4c16973d5d0f69ba3bf1bd8942a51de9a0933)

3 weeks agolib, lscpu: fix const qualifier discarded warnings in bsearch
Karel Zak [Thu, 27 Nov 2025 09:27:07 +0000 (10:27 +0100)] 
lib, lscpu: fix const qualifier discarded warnings in bsearch

Fix compilation warnings from newer compilers with stricter
const-correctness checks. When bsearch() searches in const arrays,
the result pointer must also be const to avoid discarding the
const qualifier.

Fixed in:
- lib/color-names.c: searching in static const basic_schemes[]
- sys-utils/lscpu-cputype.c: searching in const pattern arrays

The warnings were:
  lib/color-names.c:62:13: error: assignment discards 'const'
  qualifier from pointer target type
  [-Werror=discarded-qualifiers]

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 0cef3e4f5aac19bc3623883ca64c66538aa9b442)

3 weeks agolsfd: fix bsearch macro usage with glibc C23
Cristian Rodríguez [Sat, 22 Nov 2025 13:41:08 +0000 (10:41 -0300)] 
lsfd: fix bsearch macro usage with glibc C23

C23 requires bsearch to be a const preserving macro, build now fails
with

../lsfd-cmd/lsfd.c:1879:75: error: macro ‘bsearch’ passed 6 arguments, but takes just 5
 1879 |                                     nfds, sizeof(struct pollfd), pollfdcmp))
      |                                                                           ^
In file included from ../include/c.h:17,
                 from ../lsfd-cmd/lsfd.c:48:
/usr/include/stdlib.h:987:10: note: macro ‘bsearch’ defined here
  987 | # define bsearch(KEY, BASE, NMEMB, SIZE, COMPAR)                        \

  add parenthesis around expression to fix it.

(cherry picked from commit 711bda1441561bfd2eb6d45fe0bc789535c1f1a8)

3 weeks agolscpu: Add a few missing Arm CPU identifiers
Jonathan Thackray [Thu, 27 Nov 2025 16:54:40 +0000 (16:54 +0000)] 
lscpu: Add a few missing Arm CPU identifiers

(cherry picked from commit 4a1d1e33b56beccfb70d4f10e4ea1a5b91a5af2f)

3 weeks agolosetup: sort 'O' correctly for the mutual-exclusive check to work
Benno Schulenberg [Wed, 29 Oct 2025 11:03:56 +0000 (12:03 +0100)] 
losetup: sort 'O' correctly for the mutual-exclusive check to work

The options need to be in strict ascending order.

[kzak@redhat.com: - backport to stable/v2.41]

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
Signed-off-by: Karel Zak <kzak@redhat.com>
3 weeks agowdctl: remove -d option leftover
Munehisa Kamata [Tue, 28 Oct 2025 19:54:17 +0000 (12:54 -0700)] 
wdctl: remove -d option leftover

-d option was removed in commit f56338b43973 ("wdctl: allow to specify more
than one device"), but the optstring wasn't updated at that time and wdctl
can still accept the option halfway as below:

 $ wdctl -d
 wdctl: option requires an argument -- 'd'

whereas it should say:

 wdctl: invalid option -- 'd'

So update the optstring.

Fixes: f56338b43973 ("wdctl: allow to specify more than one device")
Signed-off-by: Munehisa Kamata <kamatam@amazon.com>
(cherry picked from commit 56e2c86c2c7ea012b63cd896d9ca3daa34f19565)

3 weeks agolibfdisk: (dos) fix off-by-one in maximum last sector calculation
Karel Zak [Thu, 30 Oct 2025 11:11:43 +0000 (12:11 +0100)] 
libfdisk: (dos) fix off-by-one in maximum last sector calculation

The get_disk_ranges() function incorrectly capped the last usable
sector at UINT_MAX, which could cause an overflow when calculating
partition size for MBR partition tables.

MBR stores partition size as a 32-bit value with maximum UINT_MAX.
The partition size is calculated as: size = stop - start + 1

For a partition starting at sector 0:
- If stop = UINT_MAX: size = UINT_MAX + 1 (overflow!)
- If stop = UINT_MAX - 1: size = UINT_MAX (correct maximum)

This fixes the inconsistency where dos_init() correctly warns about
disks larger than UINT_MAX sectors (2TiB - 512 bytes for 512-byte
sectors), but get_disk_ranges() allowed creating partitions that
would overflow the 32-bit size field.

Addresses: https://issues.redhat.com/browse/RHEL-122367
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 578923fe582903628ecc0d2a434af0affa3660d2)

3 weeks agobash-completion: (mount) add missing options
Christian Goeschel Ndjomouo [Mon, 13 Oct 2025 17:42:17 +0000 (13:42 -0400)] 
bash-completion: (mount) add missing options

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
(cherry picked from commit acdd6d51f4814bf4f4ebb0f6804fcfe296acdb29)

3 weeks agoumount: consider helper return status for success message
Christian Goeschel Ndjomouo [Sun, 12 Oct 2025 03:09:27 +0000 (23:09 -0400)] 
umount: consider helper return status for success message

If a helper function was executed to unmount, we simply return
without any user feedback. That can unintentionally surpress
verbose messages (`--verbose`) for non-root users who use udisks2
to mount filesystems, and unmount via the unmount.udisks2 helper.

It would be better to check the helper return status as well for
completeness and a more reliable way to test the success of the
unmount operation.

mnt_context_get_helper_status() is only called if the helper was
executed, i.e. mnt_context_helper_executed == 1, anything else
wouldnt make sense anyways.

Addresses: #3790
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
(cherry picked from commit 24478afdf0a1941e9b7049ef263677f666e73c80)

3 weeks agobash-completion: add lsfd
Karel Zak [Thu, 2 Oct 2025 12:35:43 +0000 (14:35 +0200)] 
bash-completion: add lsfd

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 9fd4790e0c8bd6b3600ae3cdb1dd47b5c7796ee8)

3 weeks agobash-completion: add blkpr
Karel Zak [Thu, 2 Oct 2025 12:17:42 +0000 (14:17 +0200)] 
bash-completion: add blkpr

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 4e9b71e1c92d69b8225ca69230fe8313dc772c4a)

3 weeks agoliblastlog2: fix operator precedence in conditional assignments
Karel Zak [Tue, 23 Sep 2025 08:46:59 +0000 (10:46 +0200)] 
liblastlog2: fix operator precedence in conditional assignments

Fix operator precedence in ll2_rename_user() where != comparison was
taking precedence over assignment, causing retval to be assigned 0 or 1
instead of the actual function return value.

Fixes: https://github.com/util-linux/util-linux/issues/3756
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 2348237f059ddb8ff4bc255235766771e1af3dd1)

3 weeks agologin-utils: fix setpwnam() buffer use [CVE-2025-14104]
Karel Zak [Mon, 8 Dec 2025 12:36:41 +0000 (13:36 +0100)] 
login-utils: fix setpwnam() buffer use [CVE-2025-14104]

This issue has been originally fixed in the master branch, but
unfortunately was not backported to stable/v2.41 yet.

References: aaa9e718c88d6916b003da7ebcfe38a3c88df8e6
References: 9a36d77012c4c771f8d51eba46b6e62c29bf572a
Signed-off-by: Karel Zak <kzak@redhat.com>
2 months agolibblkid: use snprintf() instead of sprintf()
Karel Zak [Mon, 6 Oct 2025 13:04:24 +0000 (15:04 +0200)] 
libblkid: use snprintf() instead of sprintf()

Replace sprintf() calls with snprintf() to ensure proper bounds
checking when formatting strings.

In encode.c, the check now validates snprintf() return value instead
of pre-checking buffer size, providing more robust error handling.

In probe.c, snprintf() is used with proper size calculation based on
remaining buffer space.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 041380f4ca7244df624bf7efdb5e27fdd3144175)

2 months agobash-completion: add bits to dist tarball
Karel Zak [Thu, 2 Oct 2025 11:38:13 +0000 (13:38 +0200)] 
bash-completion: add bits to dist tarball

The bits command was added in commit 6e1301d59 (text-utils: add bits
command) but the bash-completion file was not added to the autotools
Makemodule.am, causing it to be missing from release tarballs.

This resulted in meson build failures when using the tarball with
bash-completion installed, as meson.build references the file but
it doesn't exist in the tarball.

Fixes: https://github.com/util-linux/util-linux/issues/3766
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit eb0e08a76e3ebd4571b957e727847060304c32bb)

3 months agoFix meson "does not support the `+` operator" error.
Satadru Pramanik, DO, MPH, MEng [Tue, 23 Sep 2025 20:48:19 +0000 (16:48 -0400)] 
Fix meson "does not support the `+` operator" error.

Fixes #3761

3 months agobuild-sys: update release dates v2.41.2
Karel Zak [Mon, 22 Sep 2025 10:56:34 +0000 (12:56 +0200)] 
build-sys: update release dates

Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agoupdate v2.41.2-ReleaseNotes
Karel Zak [Mon, 22 Sep 2025 10:56:03 +0000 (12:56 +0200)] 
update v2.41.2-ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agopo: update uk.po (from translationproject.org)
Yuri Chornoivan [Mon, 22 Sep 2025 10:43:59 +0000 (12:43 +0200)] 
po: update uk.po (from translationproject.org)

3 months agopo: update ro.po (from translationproject.org)
Remus-Gabriel Chelu [Mon, 22 Sep 2025 10:43:59 +0000 (12:43 +0200)] 
po: update ro.po (from translationproject.org)

3 months agopo: update pl.po (from translationproject.org)
Jakub Bogusz [Mon, 22 Sep 2025 10:43:59 +0000 (12:43 +0200)] 
po: update pl.po (from translationproject.org)

3 months agopo: update nl.po (from translationproject.org)
Benno Schulenberg [Mon, 22 Sep 2025 10:43:59 +0000 (12:43 +0200)] 
po: update nl.po (from translationproject.org)

3 months agopo: update ko.po (from translationproject.org)
Seong-ho Cho [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update ko.po (from translationproject.org)

3 months agopo: update ja.po (from translationproject.org)
YOSHIDA Hideki [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update ja.po (from translationproject.org)

3 months agopo: update hr.po (from translationproject.org)
Božidar Putanec [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update hr.po (from translationproject.org)

3 months agopo: update fr.po (from translationproject.org)
Frédéric Marchal [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update fr.po (from translationproject.org)

3 months agopo: update es.po (from translationproject.org)
Antonio Ceballos Roa [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update es.po (from translationproject.org)

3 months agopo: update de.po (from translationproject.org)
Mario Blättermann [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update de.po (from translationproject.org)

3 months agopo: update cs.po (from translationproject.org)
Petr Písař [Mon, 22 Sep 2025 10:43:58 +0000 (12:43 +0200)] 
po: update cs.po (from translationproject.org)

3 months agopo-man: merge changes
Karel Zak [Mon, 22 Sep 2025 10:43:57 +0000 (12:43 +0200)] 
po-man: merge changes

3 months agopo-man: update uk.po (from translationproject.org)
Yuri Chornoivan [Mon, 22 Sep 2025 10:43:51 +0000 (12:43 +0200)] 
po-man: update uk.po (from translationproject.org)

3 months agopo-man: update ro.po (from translationproject.org)
Remus-Gabriel Chelu [Mon, 22 Sep 2025 10:43:51 +0000 (12:43 +0200)] 
po-man: update ro.po (from translationproject.org)

3 months agopo-man: update pl.po (from translationproject.org)
Michał Kułach [Mon, 22 Sep 2025 10:43:51 +0000 (12:43 +0200)] 
po-man: update pl.po (from translationproject.org)

3 months agopo-man: update de.po (from translationproject.org)
Mario Blättermann [Mon, 22 Sep 2025 10:43:51 +0000 (12:43 +0200)] 
po-man: update de.po (from translationproject.org)

3 months agotools: add git-version-next script release versioning
Karel Zak [Mon, 22 Sep 2025 09:59:49 +0000 (11:59 +0200)] 
tools: add git-version-next script release versioning

- Only works on stable/* branches (releases are generated from stable branches)
- Supports util-linux versioning: vX.Y (major), vX.Y.Z (maintenance)
- Command-line options: --rc, --release-master, --release-update
- Safety check prevents --release-master on branches with existing releases
- Testing support via --last-release and --last-xy-release overrides

Version Schema:
  Major releases:      vX.Y-rc1, vX.Y-rc2, [vX.Y-rc3], vX.Y
  Maintenance releases: vX.Y.Z-rc1, vX.Y.Z

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 7c831bbad288cec55a49c09c3b9bc24370d04828)

3 months agolibblkid: Fix probe_ioctl_tp assigning BLKGETDISKSEQ as physical sector size
Sam Fink [Wed, 17 Sep 2025 14:04:51 +0000 (10:04 -0400)] 
libblkid: Fix probe_ioctl_tp assigning BLKGETDISKSEQ as physical sector size

Fix issue introduced by PR#2908 in probe_ioctl_tp where the BLKGETDISKSEQ ioctl
result is incorrectly assigned to the topology with
blkid_topology_set_physical_sector_size instead of blkid_topology_set_diskseq.

This issue was observed while using a Debian 13 container on a RHEL 9.4 host
attempting to format a volume. The physical sector size was incorrectly
reported as 3. This issue also presents with the fdisk command,
which also uses this library to resolve physical sector size of devices.

Example fdisk output:
root@r94p121-PA:~ # fdisk --list /dev/sdb
Disk /dev/sdb: 90 GiB, 96636764160 bytes, 188743680 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 3 bytes
I/O size (minimum/optimal): 512 bytes / 3 bytes

Strace of relevant ioctls:
ioctl(3, BLKALIGNOFF, [0])              = 0
ioctl(3, BLKIOMIN, [512])               = 0
ioctl(3, BLKIOOPT, [0])                 = 0
ioctl(3, BLKPBSZGET, [512])             = 0
ioctl(3, BLKGETDISKSEQ, [3])            = 0
ioctl(3, BLKSSZGET, [512])              = 0

(cherry picked from commit 6fbde1c7db838e22b109e2e58eaa51b086758bc6)

3 months agoblkid: correct an erroneous error message
Benno Schulenberg [Tue, 16 Sep 2025 13:44:41 +0000 (15:44 +0200)] 
blkid: correct an erroneous error message

Running `blkid -p -n no /dev/sda2` would report:

  blkid: error: -u <list> argument is empty

(Mentioning -u instead of -n, and falsely claiming emptiness.)

Now the above command will report:

  blkid: invalid argument: no

(I don't think option -n needs to be mentioned, as it will be obvious
when inspecting the command line.  Not mentioning the option allows
reusing an existing error message, avoiding needless ballooning and
allowing the patch to be applied to the stable branch.)

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
(cherry picked from commit 6bbf884525cad2702b1e69a0ac022db3ef92154d)

3 months agofindmnt: (usage) add a needed equals sign before an optional argument
Benno Schulenberg [Thu, 11 Sep 2025 13:48:07 +0000 (15:48 +0200)] 
findmnt: (usage) add a needed equals sign before an optional argument

The argument of --kernel is optional, so an '=' is required when an
argument is specified.

Also tweak the wording, and add a semicolon between two phrases.

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
(cherry picked from commit 41c1dc60903803c2a4d7f286012f8e96ff06990f)

3 months agobuild-sys: update release dates v2.41.2-rc1
Karel Zak [Thu, 11 Sep 2025 09:06:44 +0000 (11:06 +0200)] 
build-sys: update release dates

Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agodocs: add v2.41.2-ReleaseNotes
Karel Zak [Thu, 11 Sep 2025 09:04:00 +0000 (11:04 +0200)] 
docs: add v2.41.2-ReleaseNotes

Signed-off-by: Karel Zak <kzak@redhat.com>
3 months agopo-man: merge changes
Karel Zak [Thu, 11 Sep 2025 08:55:40 +0000 (10:55 +0200)] 
po-man: merge changes

3 months agopo-man: update es.po (from translationproject.org)
Antonio Ceballos Roa [Thu, 11 Sep 2025 08:55:31 +0000 (10:55 +0200)] 
po-man: update es.po (from translationproject.org)

3 months agolibmount: don't report fsconfig errors with "nofail"
Karel Zak [Thu, 11 Sep 2025 07:35:58 +0000 (09:35 +0200)] 
libmount: don't report fsconfig errors with "nofail"

The new kernel API returns EINVAL on FSCONFIG_CMD_CREATE if the mount
source is inaccessible. We do not want to report this as an error when
the "nofail" mount option is specified.

Note that EINVAL may also be returned by other fsconfig() settings, so
we need to check whether a source is specified and whether it is really
inaccessible. This is just a heuristic (as with the old mount(2)).

Fixes: https://github.com/util-linux/util-linux/issues/3741
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 8a7bc1ab00d91e8a17ca8cb2907ca3c2a73381dd)

3 months agolscpu: New Arm C1 parts
Jeremy Linton [Wed, 10 Sep 2025 14:51:21 +0000 (09:51 -0500)] 
lscpu: New Arm C1 parts

Arm has announced the C1-Nano with a TRM here:
https://developer.arm.com/documentation/107753/latest

The C1-Pro with a TRM here:
https://developer.arm.com/documentation/107771/latest

The C1-Ultra with a TRM here:
https://developer.arm.com/documentation/108014/latest

The C1-Premium with a TRM here:
https://developer.arm.com/documentation/109416/latest

Signed-off-by: Jeremy Linton <jeremy.linton@arm.com>
(cherry picked from commit 50caf83d43fbee58ecb5a11e57857a027dea5148)

3 months agologger: fix buffer overflow when read stdin
Karel Zak [Wed, 10 Sep 2025 08:31:23 +0000 (10:31 +0200)] 
logger: fix buffer overflow when read stdin

$ perl -e 'print "<" . "0"x10240' | logger --prio-prefix
Segmentation fault (core dumped)

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit f9cdc91be0442b887e4a636fbb75f027f0267a84)

3 months agorev: add --zero option to --help output
Christian Goeschel Ndjomouo [Mon, 8 Sep 2025 19:48:01 +0000 (15:48 -0400)] 
rev: add --zero option to --help output

Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
(cherry picked from commit d77118f46070f71eaafa3be1c7d24226ddcc2846)

3 months agolscpu: Add NVIDIA Olympus arm64 core
Matthew R. Ochs [Tue, 2 Sep 2025 20:28:36 +0000 (13:28 -0700)] 
lscpu: Add NVIDIA Olympus arm64 core

Add an entry for NVIDIA Olympus arm64 core.

Signed-off-by: Matthew R. Ochs <mochs@nvidia.com>
(cherry picked from commit 908777470d403ec30c525472ba0d3701c9c5a223)

3 months agohardlink: (man) add note note about ULFILEEQ_DEBUG=
Karel Zak [Wed, 3 Sep 2025 09:57:06 +0000 (11:57 +0200)] 
hardlink: (man) add note note about ULFILEEQ_DEBUG=

Addresses: https://github.com/util-linux/util-linux/discussions/3323
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit d073aab9d34eea205545c77222947691f4abf5aa)

3 months agolibfdisk: (script) improve separator usage in named-fields dump
Karel Zak [Wed, 3 Sep 2025 09:30:57 +0000 (11:30 +0200)] 
libfdisk: (script) improve separator usage in named-fields dump

Ensure that name=value pairs are separated by commas.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c5e6712f29c18659f8bd9a567dc7f849a2a3cf3b)

3 months agolibfdisk: (script) fix device name separator parsing
Karel Zak [Wed, 3 Sep 2025 08:54:06 +0000 (10:54 +0200)] 
libfdisk: (script) fix device name separator parsing

In the named-fields script format, the colon is used as the separator
between the device name and other values. The device name may also
contain colons. This commit ensures it is treated as a separator only
when there is a space before or after the colon.

Note that the device name is optional and may be omitted. There is no
escaping for problematic characters in the name. Use " : " as the
separator.

Fixes: https://github.com/util-linux/util-linux/issues/3723
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 4eab9175dfd62c1d1a0bbc43a49ca8a85e9adac7)

3 months agozramctl: ignore ENOENT when setting max_comp_streams
Jiang XueQian [Sat, 30 Aug 2025 09:02:59 +0000 (17:02 +0800)] 
zramctl: ignore ENOENT when setting max_comp_streams

The `max_comp_streams` attribute of zram devices has been deprecated and
all writes were silently ignored by the kernel since 2016. It was
finally removed in 6.15, causing zramctl to fail on ENOENT, when it
should just ignore the error.

Signed-off-by: Jiang XueQian <jiangxueqian@gmail.com>
(cherry picked from commit e4514111ebb6df5f22a0769a9dfb2338b9c6c81a)

3 months agofindmnt: add missing newline in --raw, --pair and --list output formats
Christian Goeschel Ndjomouo [Sat, 30 Aug 2025 02:41:04 +0000 (22:41 -0400)] 
findmnt: add missing newline in --raw, --pair and --list output formats

Addresses: #3711
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
(cherry picked from commit 5dfb06873eb07389cc2aa9276adb7791bb5f40ab)

3 months agoman: Fixed incorrect ipcrm options
Prasanna Paithankar [Fri, 29 Aug 2025 12:43:17 +0000 (18:13 +0530)] 
man: Fixed incorrect ipcrm options

Signed-off-by: Prasanna Paithankar <paithankarprasanna@gmail.com>
(cherry picked from commit 40d088c63ce7742180e7d7e813dcababd4c478f5)

3 months agosfdisk: reject spurious arguments for --reorder/--backup-pt-sectors
Thomas Weißschuh [Sun, 24 Aug 2025 09:45:45 +0000 (11:45 +0200)] 
sfdisk: reject spurious arguments for --reorder/--backup-pt-sectors

These commands only accept a single device argument.
Reject any additional unexpected arguments.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
(cherry picked from commit 3c98bdcc1f9b13de8a9d54d034efea789978c1f9)

3 months agogetopt: document special symbols that should not be used as option characters
cgoesche [Fri, 22 Aug 2025 21:31:24 +0000 (17:31 -0400)] 
getopt: document special symbols that should not be used as option characters

getopt(3) routines return `?` or `:` when an unknown option character is encountered
or an option is missing its required argument, respectively. It also disallows
`;` as an option character. Documenting this makes users aware that they may not use
these reserved symbols as option characters, e.g. `-?` which is used in some older programs.

Addresses: #2995
Signed-off-by: Christian Goeschel Ndjomouo <cgoesc2@wgu.edu>
(cherry picked from commit 9b4f1ca3342bdff7e1c3d8eaf3735cf821f407bc)

3 months agozramctl: fix MEM-USED column description
Jérôme Poulin [Fri, 22 Aug 2025 03:54:17 +0000 (23:54 -0400)] 
zramctl: fix MEM-USED column description

The MEM-USED column was incorrectly documented as showing current
memory consumption. This is due to confusing naming in the kernel's
zram implementation:

- Kernel field "mem_used_total" (3rd in mm_stat) = current memory usage
- Kernel field "mem_used_max" (5th in mm_stat) = peak memory usage

zramctl maps these as:
- TOTAL column <= mem_used_total (current usage)
- MEM-USED column <= mem_used_max (peak usage)

The misleading "MEM-USED" name suggests current usage, but it actually
shows the peak memory usage (high water mark) since device creation
or last reset. This is tracked by the kernel's max_used_pages which
only increases when current usage exceeds the stored maximum.

Fixed description from:
"memory zram have been consumed to store compressed data" to
"peak memory usage to store compressed data".

Mise à jour de la traduction française.

(cherry picked from commit 616c88fb9565017c1a08c8869d2559b8d218c443)

3 months agoinclude/mount-api-utils: avoid using sys/mount.h
Karel Zak [Thu, 21 Aug 2025 07:59:10 +0000 (09:59 +0200)] 
include/mount-api-utils: avoid using sys/mount.h

The file is unnecessary and introduces duplicate #define of MS_* macros.

Fixes: https://github.com/util-linux/util-linux/issues/3674
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 2a9b48d20d74f65ac708b3bcee6a7e2a61aadf88)

3 months agoliblastlog2: markup fixes for man pages
Mario Blättermann [Thu, 21 Aug 2025 07:35:47 +0000 (09:35 +0200)] 
liblastlog2: markup fixes for man pages

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit d6c72456dc5e88fe124e0299840352d12ee8aa05)

3 months agologger: fix incorrect warning message when both --file and a message are specified
Alexander Kappner [Wed, 13 Aug 2025 11:10:28 +0000 (04:10 -0700)] 
logger: fix incorrect warning message when both --file and a message are specified

Logger warns that when both --file and a message are given, the message is ignored.
It does the opposite. Fix the warning message to conform to the observed behavior.

Example:
echo "You will not see this file in the log" > file.txt
logger -f file.txt "You will see this message in the log"

Signed-off-by: Alexander Kappner <agk@godking.net>
(cherry picked from commit 2a31355b11c3714cac2b6b60565b639aa32388f1)

3 months agomkfs.cramfs: avoid uninitialized value [coverity scan]
Karel Zak [Tue, 29 Jul 2025 09:40:16 +0000 (11:40 +0200)] 
mkfs.cramfs: avoid uninitialized value [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c24654e0d5976fac7f785b8bf4f8217cc1df2772)

3 months agotests/helpers/test_sigstate.c: explicitly reset SIGINT to default action after trapping
Hongxu Jia [Mon, 28 Jul 2025 12:35:13 +0000 (20:35 +0800)] 
tests/helpers/test_sigstate.c: explicitly reset SIGINT to default action after trapping

After upgrading bash to 5.3 to contain commit [1], if SIGINT was trapped in
asynchronous subshell, bash called set_signal_async_ignored to make sure
processes that are created by this asynchronous subshell to ignore SIGINT.

And it caused test case `kill/decode' failed, the signal INT was existed in
both of Blocked and Ignored

$ ./tests/run.sh --use-system-commands --parsable --show-diff   kill/decode
...
diff-{{{
|--- /usr/lib/util-linux/ptest/tests/expected/kill/decode        2011-04-05 23:00:00.000000000 +0000
|+++ /usr/lib/util-linux/ptest/tests/output/kill/decode  2025-07-28 12:09:46.279000000 +0000
@@ -16,5 +16,5 @@
 Pending (thread): INT ILL
 Pending (process): USR1
 Blocked: INT ILL ABRT FPE USR1 SEGV TERM
-Ignored: HUP QUIT TRAP PIPE ALRM
+Ignored: HUP INT QUIT TRAP PIPE ALRM
 Caught: ILL USR1
}}}-diff
...

Explicitly reset SIGINT to default action after trapping, then the
test case `kill/decode' works on both of old (<5.3) and new (>=5.3) bash

[1] https://cgit.git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=a5d2617c7a7e602ace1f4149987cdfd075c4e762

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
(cherry picked from commit 6d46bbc0896b963486546d5d1b3d9241a2d5d0f8)

3 months agolibblkid: (ext) reduce false positive
胡玮文 [Mon, 28 Jul 2025 06:32:13 +0000 (14:32 +0800)] 
libblkid: (ext) reduce false positive

Signed-off-by: 胡玮文 <huweiwen.hww@alibaba-inc.com>
(cherry picked from commit 0c5d55e52d27be933e9e61b82bd386943bd9e05c)

3 months agosetpriv: Improve getgroups() Portability
Karel Zak [Mon, 21 Jul 2025 06:16:25 +0000 (08:16 +0200)] 
setpriv: Improve getgroups() Portability

setpriv(1) is Linux-only, and on Linux, getgroups() returns at least one group.
However, it's better to use more portable and generic code patterns and assume
that getgroups() can return zero.

Fixes: https://github.com/util-linux/util-linux/issues/3654
Reported-by: Alejandro Colomar <alx@kernel.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 434a5633a563066357bbc3f331838ed41041ec1a)

3 months agolibblkid: improve UUID_SUB= description
Karel Zak [Thu, 24 Jul 2025 10:48:00 +0000 (12:48 +0200)] 
libblkid: improve UUID_SUB= description

Fixes: https://github.com/util-linux/util-linux/issues/3657
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit fc56a4c50a009ea6850f6c585cbbd53819399ed4)

3 months agofsck.cramfs: check buffer size for memcpy()
Karel Zak [Mon, 21 Jul 2025 07:48:06 +0000 (09:48 +0200)] 
fsck.cramfs: check buffer size for memcpy()

- reuse MAX_INPUT_NAMELEN
- check path buffer size before memcpy() to the buffer
- check for zero path before use it

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit caf79c6073bed928653ed4a8c495c5f111973afb)

3 months agotests: add color names test
Karel Zak [Mon, 25 Aug 2025 11:07:21 +0000 (13:07 +0200)] 
tests: add color names test

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 36a3c19e9a10afe83c9f3e6570521ad4ad252ef2)

3 months agolib/color-names: fix stupid bugs
Karel Zak [Mon, 25 Aug 2025 10:05:01 +0000 (12:05 +0200)] 
lib/color-names: fix stupid bugs

- sort "white" -> "yellow"
- fix typo "lightgray,"

Fixes: https://github.com/util-linux/util-linux/issues/2863
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 1b9e3ffd2e4e1e18c6056c572547e1803923487e)

3 months agolib/color-names: Fix color name canonicalization
Karel Zak [Tue, 15 Jul 2025 13:35:05 +0000 (15:35 +0200)] 
lib/color-names: Fix color name canonicalization

Return NULL rather than a random string if it cannot be translated to
the color sequence.

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 44ebe68c24da0bcf5aa1f48017d47d2d8995b0ed)

3 months agolib/path: avoid double free() for cpusets
Karel Zak [Wed, 2 Jul 2025 10:25:45 +0000 (12:25 +0200)] 
lib/path: avoid double free() for cpusets

Addresses: https://github.com/util-linux/util-linux/issues/3641
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 4581ede384f22983d6155768635ce43cb5304cb0)

3 months agolsblk: fix possible use-after-free
Karel Zak [Wed, 2 Jul 2025 09:48:22 +0000 (11:48 +0200)] 
lsblk: fix possible use-after-free

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 02955d9434396df4019132351d8264b74811dc3f)

3 months agobash-completion: fix function name of enosys completion
Koichi Murase [Tue, 1 Jul 2025 13:39:23 +0000 (22:39 +0900)] 
bash-completion: fix function name of enosys completion

The function "_enosys_module" referenced by the completion setting on
the last line of "bash-completion/enosys" is not defined in the
current master.  As reported in Ref. [1], this causes the following
error on an attempt at argument completion for the "enosys" command:

  bash: _enosys_module: command not found

[1] https://www.reddit.com/r/Fedora/comments/1llmu0w/comment/n00y98k/

Also, the function "_waitpid_module" defined in
"bash-completion/enosys" overwrites another completion function of the
same name defined in "bash-completion/waitpid".  This patch renames
the function in "bash-completion/enosys" to the correct one,
"_enosys_module".

(cherry picked from commit c83058dcd3a4dc703d64e245eff2d5db281a1b79)

3 months agolsblk: fix memory leak [coverity scan]
Karel Zak [Tue, 1 Jul 2025 08:00:19 +0000 (10:00 +0200)] 
lsblk: fix memory leak [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit b13f60104b646b45dc9bf43408e6fdec03382ad9)

3 months agoman: Replace RETURN VALUE with EXIT STATUS in section 1
Jesse Rosenstock [Mon, 30 Jun 2025 18:32:49 +0000 (20:32 +0200)] 
man: Replace RETURN VALUE with EXIT STATUS in section 1

According to man-pages(7), sections 1 and 8 should normally use
EXIT STATUS, while sections 2 and 3 should use RETURN VALUE.

https://man7.org/linux/man-pages/man7/man-pages.7.html

Signed-off-by: Jesse Rosenstock <jmr@google.com>
(cherry picked from commit 9dc97c99ae5b501a941dd31485671309a8f94573)

3 months agomore: temporarily ignore stdin when waiting for stderr
Karel Zak [Mon, 30 Jun 2025 10:20:13 +0000 (12:20 +0200)] 
more: temporarily ignore stdin when waiting for stderr

more waits for user commands on stderr, but at the same time, it
monitors sigalfd and stdin (for data and POLLHUP|POLLNVAL). We need to
temporarily ignore stdin if there is new data waiting for read()
(e.g., dmesg | more); otherwise, more_key_command() will end in a busy
loop.

Fixes: https://github.com/util-linux/util-linux/issues/3634
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 85cbb5f5449be75d51b064681f0d92adf31f59be)

3 months agolib/strutils: add ul_ prefix to strrep() and strrem() functions
Karel Zak [Mon, 30 Jun 2025 09:15:30 +0000 (11:15 +0200)] 
lib/strutils: add ul_ prefix to strrep() and strrem() functions

Addresses: https://github.com/util-linux/util-linux/issues/3626
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 7bb1151e559710f18682454384c99d7cd67f35fb)

3 months agolib/strutils: add ul_ prefix to split() function
Karel Zak [Mon, 30 Jun 2025 09:15:30 +0000 (11:15 +0200)] 
lib/strutils: add ul_ prefix to split() function

Addresses: https://github.com/util-linux/util-linux/issues/3626
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 6b627aa34d2977eb347b32040c1c3075daad3d1d)

3 months agolib/strutils: add ul_ prefix to strappend() functions
Karel Zak [Mon, 30 Jun 2025 09:15:30 +0000 (11:15 +0200)] 
lib/strutils: add ul_ prefix to strappend() functions

Addresses: https://github.com/util-linux/util-linux/issues/3626
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit d42e5e4bc355277b820d98768e2fda52e2d08e76)

3 months agolib/strutils: add ul_ prefix to strconcat() functions
Karel Zak [Mon, 30 Jun 2025 09:15:30 +0000 (11:15 +0200)] 
lib/strutils: add ul_ prefix to strconcat() functions

Addresses: https://github.com/util-linux/util-linux/issues/3626
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit c128ee3ea488174230065f6a35286e01e98996f8)

3 months agolsblk: use md as fallback TYPE when md/level empty
codefiles [Sat, 28 Jun 2025 00:53:16 +0000 (20:53 -0400)] 
lsblk: use md as fallback TYPE when md/level empty

(cherry picked from commit 6bed45b965b22c8ea5c10c43320c19cf84fd8cfa)