mama_forth_words: KILL must not physics-retire Hera before refusing her
S" Hera" KILL called vm_physics_retire(hera_id) before capsule_vm_kill()'s own Hera guard ever ran. Hera's self-referential parent_vm_id makes vm_physics_find_root_id() return her own id immediately, so vm_physics_retire() treated her as an unreachable root and zeroed the fleet's entire execution_heat_q48 sum -- silently, with only the harmless-looking "cannot kill Hera" message as output. Guard the retire call the same way capsule_vm_kill() already guards the actual kill. Three-arch acceptance boot, all clean to ok>: logs/20260813-083429/amd64, logs/20260813-083551/aarch64, logs/20260813-083738/riscv64. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
b929a59f3d
commit
db6640682b
@@ -520,11 +520,15 @@ void mama_word_kill(VM *vm)
|
||||
|
||||
/* Resolve vm_id and fan out its heat to survivors before the registry
|
||||
* entry is torn down -- capsule_vm_kill() only takes a name and
|
||||
* leaves no live entry to query afterward. */
|
||||
* leaves no live entry to query afterward. Excludes Hera: her
|
||||
* self-referential parent_vm_id makes vm_physics_retire() treat her
|
||||
* as her own unreachable root and zero the fleet's entire heat sum,
|
||||
* before capsule_vm_kill()'s own Hera guard below ever runs. */
|
||||
{
|
||||
VMRegistryEntry entry;
|
||||
if (capsule_vm_find_by_name_nocase(name_buf, &entry) == 0 &&
|
||||
entry.state == VM_STATE_LIVE) {
|
||||
entry.state == VM_STATE_LIVE &&
|
||||
!vm_uuid_is_hera(entry.vm_id)) {
|
||||
vm_physics_retire(entry.vm_id);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user