Linux process start times are dated up to a second early, so a game a launcher hands over is not followed #216
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ethan-hann/SavePoint#216
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
LinuxProcessInspector dated every process start from /proc/stat btime, a whole second with the fraction dropped, so every start time on Linux was up to a second early (0.93 s on the test VM's current boot). When a launcher stub exits before the session watcher's first look, the watcher links the handed-over game by when and where it started, requiring it to start at or after the session's start; a game dated 0.9 s early was rejected and the session ended as "the game never appeared". It hits any Linux player whose launcher exits at once, on most boots. Found by RealSessionTests on the Linux test VM.
Fix: date starts from the clock minus /proc/uptime (hundredths of a second), cached per inspector, falling back to btime when the two disagree by more than about a second (containers), and take the session's start time before the process is started so a game that starts a few ms after an unseen stub is never rejected.
Shipped in 0.9.17 (PR 227).