From: Zbigniew Jędrzejewski-Szmek Date: Tue, 12 May 2026 15:12:59 +0000 (+0200) Subject: core: when skipping state deserializing units, also skip job subsections (#41957) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=143f5911b158d05b36c5b8b40456f5908c0b4d36;p=thirdparty%2Fsystemd.git core: when skipping state deserializing units, also skip job subsections (#41957) If a unit has active jobs, when it gets serialized there are job subsections, each with their own empty line marker. The skipping function ignores this and skips until the marker, but then leaves the job in place, breaking deserialization. Consume jobs subsections too. This shows up now that there's TEST-07-PID1.alias-corruption, which occasionally fails when the aliased unit happens to still have a job when the reexec happens. ``` [ 967.551630] TEST-07-PID1.sh[179]: + echo 'Testing with: systemctl daemon-reexec' [ 967.551630] TEST-07-PID1.sh[179]: Testing with: systemctl daemon-reexec [ 968.405274] TEST-07-PID1.sh[179]: + echo '--- Attempt 1/3 ---' [ 968.405274] TEST-07-PID1.sh[179]: --- Attempt 1/3 --- [ 968.698641] TEST-07-PID1.sh[179]: + echo 'Running daemon-reexec...' [ 968.698641] TEST-07-PID1.sh[179]: Running daemon-reexec... [ 969.130261] TEST-07-PID1.sh[179]: + echo 'legit.service PID remains 1282. Attempt 1 passed.' [ 969.130261] TEST-07-PID1.sh[179]: legit.service PID remains 1282. Attempt 1 passed. [ 970.870456] TEST-07-PID1.sh[179]: + echo '--- Attempt 2/3 ---' [ 970.870456] TEST-07-PID1.sh[179]: --- Attempt 2/3 --- [ 971.267205] TEST-07-PID1.sh[179]: + echo 'Running daemon-reexec...' [ 971.267205] TEST-07-PID1.sh[179]: Running daemon-reexec... [ 971.715743] TEST-07-PID1.sh[179]: + echo 'legit.service PID changed from 1282 to 1643!' [ 971.715743] TEST-07-PID1.sh[179]: legit.service PID changed from 1282 to 1643! ``` https://github.com/systemd/systemd/actions/runs/25376867873/job/74414201255 --- 143f5911b158d05b36c5b8b40456f5908c0b4d36