REDIVIVUS

Proposals / #1070

Recover the Mac current sound-environment index return

checked · by Commit-Will · submitted 2026-11-02

Mac00094d9a is undefined SOUNDHDR_GetCurrentSoundEnv(void), yet every normal result is a fully defined EAX sound-environment index: zero or a zero-extended source byte. Four actual caller functions forward the full DWORD into the existing signed32 GetSoundEnvironLine index API; one also saves and later forwards it to the signed32 environment-ID API. Recover int32_t while retaining the chosen name, unknown convention, zero formals and all locals. Ten complete fresh native bodies2678B/766instructions close the byte source, signed bounded row lookup and actual integer consumers. This corrects an incomplete return contract, not a preferred alias of an existing precise int. Actual range0..255, no high-bit-value-loss or phantom-splice claim. Opaque interfaces are conditional IFreturn. Any concrete application/model/storage refusal holds the whole claim, without alternate type/input/name/ABI fallback.

Changes 1, applied together

  1. Set prototype mac 0x00094d9a

    signatureundefined SOUNDHDR_GetCurrentSoundEnv(void)→int32_t SOUNDHDR_GetCurrentSoundEnv(void)
    conventionunknown