Antonio Alvarez Feijoo
dd23292c08
gpt-auto-generator: fix typo
2023-03-21 18:57:59 +09:00
Zbigniew Jędrzejewski-Szmek
cd36f4d79f
Merge pull request #26867 from dtardon/list-dependencies-circular
...
Fix printing of circular dependencies
2023-03-21 09:40:46 +01:00
Dmitry V. Levin
f0a16c9ae8
udev-rules: add another check for conflicting expressions
...
Log an error when a rule line contains the following kind of conflicting
match expressions:
KEY=="foo", KEY=="bar"
2023-03-21 09:34:50 +09:00
OMOJOLA JOSHUA DAMILOLA
92035969e0
compare-operator: added unit tests
2023-03-20 17:54:02 +00:00
Yu Watanabe
719bbb365b
Merge pull request #26875 from yuwata/core-transaction
...
core/transaction: several fixes for merge_unit_ids()
2023-03-21 00:42:30 +09:00
Yu Watanabe
00546c18fd
strv: introduce strv_print_full()
2023-03-20 09:32:09 +01:00
Yu Watanabe
de2c62e847
bootctl: fix wrong type comparison
2023-03-20 13:58:20 +09:00
Dmitry V. Levin
5004aa84ac
udev-rules: fix check for conflicting and duplicate expressions
...
Fix check for conflicting and duplicate expressions of types that
support alternative patterns.
Fixes: 3ec58d0cd8 ("udev-rules: check for conflicting and duplicate expressions")
2023-03-19 11:32:09 +00:00
Dmitry V. Levin
8c499a61c4
Revert "udev: prepare memory for extra NUL termination for NULSTR"
...
This reverts commit cd3c8a117c which was
papering over the bug instead of a proper fix made by the previous
commit.
2023-03-19 11:32:09 +00:00
Dmitry V. Levin
c43ff248f9
udev-rules: fix matching of token types that support alternative patterns
...
For those token types that support matching of alternative patterns,
their token values are interpreted as nulstr, so make sure the parser
does the right thing and makes these token values terminated by two
subsequent NULs so they could be safely interpreted as nulstr.
Before this fix, the following rules would result to "echo foo" invocation:
ENV{foo}=", RUN"
ENV{foo}=="bar", RUN+="echo foo"
because the value of `ENV{foo}` is treated as nulstr, and it used to match
against alternative patterns, in this case `bar`, `, RUN`, and `="echo foo`.
Fixes: 25de7aa7b9 ("udev: modernize udev-rules.c")
2023-03-19 11:32:09 +00:00
Yu Watanabe
432f1fa8c7
loop-util: add more debugging logs in loop_configure()
2023-03-19 20:32:09 +09:00
Yu Watanabe
3867264c78
Merge pull request #26880 from yuwata/test-tmpfiles
...
tmpfiles: cleanups
2023-03-19 02:49:11 +09:00
Yu Watanabe
9edf5752e5
Merge pull request #26879 from mrc0mmand/cocci
...
tree-wide: simplify x ? x : y to x ?: y where applicable
2023-03-19 02:48:39 +09:00
Yu Watanabe
056ff0b455
tmpfiles: show file type in octal, instead of hex
2023-03-18 22:27:41 +09:00
Frantisek Sumsal
1da3cb8141
tree-wide: simplify x ? x : y to x ?: y where applicable
2023-03-18 14:23:11 +01:00
Yu Watanabe
0bc2bcf4fe
Merge pull request #26759 from medhefgo/boot-stack-protector
...
boot: Add support for stack protector/trapping math/ubsan
2023-03-18 15:07:45 +09:00
Yu Watanabe
a9938fb3cb
Merge pull request #26862 from yuwata/uki-util
...
uki-util: export functions of inspecting kernel
2023-03-18 15:04:54 +09:00
Yu Watanabe
aa5ef80130
Merge pull request #26861 from yuwata/exec-util
...
exec-util: introduce execute_strv() and EXEC_DIR_SKIP_REMAINING
2023-03-18 15:04:16 +09:00
Yu Watanabe
1f3792bfca
Merge pull request #26855 from DaanDeMeyer/repart-fixes
...
Repart fixes
2023-03-18 15:03:38 +09:00
Yu Watanabe
5803c24da5
core/transaction: do not log "(null)"
...
As we ignores the failure in merge_unit_ids(), so unit_ids may be NULL.
2023-03-18 12:19:44 +09:00
Yu Watanabe
999f165143
core/transaction: make merge_unit_ids() return non-NULL on success
2023-03-18 12:19:44 +09:00
Yu Watanabe
366eced4c8
core/transaction: make merge_unit_ids() always return NUL-terminated string
...
Follow-up for 924775e8ce .
The loop run with `STRV_FOREACH_PAIR()`, hence `if (*(unit_id+1))` is
not a good way to detect if there exist a next entry.
Fixes #26872 .
2023-03-18 12:12:05 +09:00
Mike Yuan
6c2caf5053
Merge pull request #26863 from yuwata/kernel-install-cleanups
...
kernel-install: cleanups
2023-03-18 02:28:50 +08:00
Mike Yuan
f05b4bb9a7
sleep: fix default values unmatched with manual
2023-03-18 02:28:22 +08:00
David Tardon
7a26ed2ae2
systemctl: move printing of state to the printing func.
...
No functional change, just refactoring.
2023-03-17 14:50:40 +01:00
Yu Watanabe
b0e339547f
kernel-install: check all entry candidates first, then check existence of $pref/loader/entries only once
...
If we have multiple entries in $ENTRY_TOKEN_SEARCH, and $pref/loader/entries
exists, then previously we would always exit after the first candidate and
ignore the second and later candidates.
Follow-up for 1b43f86893 .
2023-03-17 20:41:17 +09:00
Yu Watanabe
561d801370
Revert "kernel-install: also try to find $BOOT by partition GUID"
...
This reverts commit 41f39e2144 .
From the post merge comment in #26648 :
> Hmm, this is highly problematic, no? if I boot from my ssd and then
> plug in a fedora live usb stick, then there will be two ESPs around,
> the one from my ssd and the one from the live usb one, and this code
> might find the wrong one and bad things will happen
2023-03-17 20:41:17 +09:00
Yu Watanabe
16af02cd97
uki-util: move functions for inspecting kernel to uki-util.[ch]
2023-03-17 20:40:34 +09:00
Yu Watanabe
c8eced395b
bootctl: introduce inspect_kernel()
...
Then, now verb_kernel_identify() and verb_kernel_inspect() can share
most of the code.
2023-03-17 20:40:34 +09:00
Yu Watanabe
8102ff2e3d
bootctl: introduce uki_read_pretty_name()
...
No functional change, just prepration for later commits.
2023-03-17 20:40:34 +09:00
Yu Watanabe
748b15c277
bootctl: find matching section in read_pe_section()
...
No functional change, just refactoring.
2023-03-17 20:40:34 +09:00
Yu Watanabe
03221e746d
bootctl: return 0 instead of EXIT_SUCCESS
2023-03-17 20:40:34 +09:00
Yu Watanabe
ab94d98b29
bootctl: move verb_kernel_identity()
...
No functional change, just for making beautify later diffs.
2023-03-17 20:40:34 +09:00
Yu Watanabe
58f5f60f1a
os-util: add missing headers
...
For 'bool' and 'usec_t'.
2023-03-17 20:40:34 +09:00
Yu Watanabe
6ad9af0b13
exec-util: introduce EXEC_DIR_SKIP_REMAINING flag
...
Will be used in later commits.
2023-03-17 20:38:15 +09:00
Yu Watanabe
f691157b87
exec-util: extract the core logic of execute_directories() as execute_strv()
...
Then, we can use it with a custom enumerator of executables.
No functional change, preparation for later commits.
2023-03-17 20:38:15 +09:00
Yu Watanabe
753e38d984
exec-util: enumerate executables earlier
...
Then, return earlier if no executable found.
2023-03-17 20:38:15 +09:00
Yu Watanabe
fb0e5f12c6
exec-util: drop meaningless casts
2023-03-17 20:38:15 +09:00
Yu Watanabe
8e8df8292a
exec-util: tighten variable scope a bit
2023-03-17 20:38:15 +09:00
Daan De Meyer
dfb487ef74
Merge pull request #26849 from DaanDeMeyer/fwd-colors
...
journald-console: Add colors when forwarding to console
2023-03-17 12:02:35 +01:00
David Tardon
c6b9baaa5b
systemctl: drop stray empty line
2023-03-17 10:47:44 +01:00
David Tardon
bb7c4a93ea
systemctl: always print circular deps. at the end
...
Before:
a.target
○ └─b.target
├─...
● └─paths.target
After:
a.target
○ └─b.target
● ├─paths.target
└─...
2023-03-17 10:47:04 +01:00
Jan Janssen
1e7ff4ba88
boot: Add undefined sanitizer support
...
Sadly, no stack traces, but this is better than nothing.
2023-03-17 10:39:39 +01:00
Jan Janssen
0b482b37f9
meson: Share more C flags
2023-03-17 10:39:32 +01:00
Jan Janssen
f64f82aa8d
boot: Add support for -ftrapv
2023-03-17 10:35:29 +01:00
Jan Janssen
48e1b2c250
boot: Add support for -fstack-protector
2023-03-17 10:35:29 +01:00
Jan Janssen
a05f03225e
boot: Detect nested assertions
2023-03-17 10:35:29 +01:00
David Tardon
5a4711e489
systemctl: fix formatting of circular dep.
...
Before:
a.target
○ └─b.target
└─...
● └─paths.target
After:
a.target
○ └─b.target
├─...
● └─paths.target
2023-03-17 10:09:07 +01:00
David Tardon
a9f2f486f3
systemctl: fix indentation of circular deps
...
We're still at level `level` here.
Before:
b.target
○ ├─a.target
│ └─...
● └─paths.target
After:
b.target
○ ├─a.target
│ └─...
● └─paths.target
Fixes #26052 .
2023-03-17 10:05:47 +01:00
Daan De Meyer
6742397921
Merge pull request #26783 from yuwata/loop-ref-follow-up
...
udev: slightly extend comment and add more tests
2023-03-17 10:00:43 +01:00