fix(compat): pad AC unpack buffers correctly above 2 GB (2026.10.5.23)
AC pads its pack/unpack cursor to 4 bytes with a signed "ptr % 4". In the large-address-aware client a buffer above 0x80000000 gives a negative remainder, AC pads 4 bytes too many, zeroes live data and parses garbage counts: kelpie's open-world crashes in motion-table and setup unpacks (dump 2026-10-10 10:32, motion table 0x09000009 at 0x80438034). Early init now rewrites the 190 padding sites (and r, 0x80000003 followed by the sign fix-up and the "already aligned" je) to and r, 3 in memory. Kill-switch: engine.json EnableLargeAddressAlignmentFix=false. Offline checks in tools/LargeAddressAlignmentTests. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
8922c2d06a
commit
fdc7ea71bc
7 changed files with 517 additions and 0 deletions
|
|
@ -216,6 +216,9 @@ public static class EntryPoint
|
|||
TryPreloadMinHookForEarlyInit();
|
||||
|
||||
RunInitStep("early multi-client hooks", MultiClientHooks.Initialize);
|
||||
// Before AC's main thread resumes, so no dat or network unpack runs the stock
|
||||
// signed padding; a hot reload finds every site already patched.
|
||||
RunInitStep("large-address alignment fix", LargeAddressAlignmentPatch.Initialize);
|
||||
// DatFileShareHooks force-shares AC's data files at the CreateFile
|
||||
// layer so we can coexist with Decal-injected clients that other
|
||||
// launchers (Thwargle etc.) have already opened against the same
|
||||
|
|
|
|||
Loading…
Reference in a new issue