Files
codex/codex-rs
Eric Traut 36df9544a3 Clean up Unix app-server control-socket startup lock files (#51191)
## Why

Unix control-socket shutdown removes the socket and rendezvous link but leaves the startup lock file behind.

## What changed

Keep a removable startup lock with the control-socket guard and release the lock after publishing the rendezvous link. On cleanup, reacquire the lock and verify that the path still identifies the same file before removing it.

Use nonblocking acquisition with asynchronous retries, checking file identity after acquisition to handle lock-file replacement.

## Testing

Add tests for nonblocking lock contention and dangling symlink rejection, and extend the control-socket lifecycle test to verify that the lock file is removed on shutdown.

GitOrigin-RevId: 469ed5269f32ae1c0655d40d28519ef5e94ba6be
2026-10-05 22:38:32 +00:00
..
…
…
…