mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-11-22 02:12:16 +00:00
583fa72b44
BuildUtils::sh() runs each build command in its own process group, so SIGKILL on the wrapper leaves that group running. The lock records the wrapper, so the next build proved the wrapper dead and took the lock, and two builds then wrote one checkout and one mock target. cancel_build keeps the lock on purpose when a group survives its cleanup, and that recovery undid the retention. sh() now records the group on every lock this process holds, before it restores the signal mask, so a cancellation cannot land between the fork and the record. It drops the record after the group is reaped. cancel_build drops it only when kill(0, -pgid) answers ESRCH, which is the test it already used to decide it may release; on the retention path the record stays, and a later acquire reads it and refuses the lock. The vendored XCAT::NFSLock carries the rule: an owner is recoverable only when it is provably dead and every attached group is gone. detach refuses while any process is in the group, so the retention does not depend on which call site remembered to run. Depends on xcat-dep/#93, which carries the same change to the original. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
Shared FIPS shell policy
Edit fips-policy.sh, then run:
perl build-utils/sync-fips-policy --write
perl build-utils/sync-fips-policy --check
Commit the source and both updated runtime libraries together. The generated
blocks in Genesis usr/lib/xcat/fips.sh and postscripts xcatlib.sh stay tracked
so source-checkout callers and standalone packages need no generation step.
The RPM and Debian builders reject stale blocks before building either package.
Keep caller-specific helpers outside the generated block. The policy source must remain POSIX shell. It must not depend on the other package at runtime.