REDIVIVUS

Proposals / #616

Recover the Mac client-event dispatcher's four stack inputs

applied · by Commit-Will · submitted 2026-11-01, applied 2026-11-01

Ghidra vmac 105 · 3bccb89

CUNITEVENT_DispatchCallbacks currently has an unknown-convention zero-argument signature, but its complete94-byte body reads four stack inputs at EBP+8/+c/+10/+14. The sole code caller explicitly supplies all four at0010793b..00107952. The second is its target unit: the body uses unit+0x90 as the event-list head, matching the existing client-side layout and the allocator's link writes. Restore cdecl and four4-byte inputs; keep three forwarded/matched words opaque undefined4 rather than infer pointer or signedness semantics. Preserve unknown-byte return meaning via registered undefined1; the caller ignores EAX. No callback/struct changes, meaningful return, Windows twin or runtime effect claimed.

Changes 1, applied together

  1. Set prototype mac 0x0012b5ca

    signatureundefined CUNITEVENT_DispatchCallbacks(void)→undefined1 CUNITEVENT_DispatchCallbacks(undefined4 dwMatchKey, D2UnitStrc * pUnit, undefined4 dwCallbackArg1, undefined4 dwCallbackArg2)
    conventionunknown→__cdecl