mirror of
https://github.com/alfishe/amiga-bootcamp.git
synced 2026-10-27 17:26:28 +00:00
Fix wrong LVO offsets in the exec and dos tables
exec.library: Forbid, Permit, Disable and Enable were in the wrong slots. Forbid/Permit move to -132/-138 and Disable/Enable to -120/-126. dos.library: the table left out six private vectors but kept counting as though they were not there, so every row after a missing one was shifted, ending 36 bytes out. Restores ClearVec (-162), NoReqLoadSeg (-168), Cli (-492), DosNameFromAnchor (-852), PathPart (-876) and CliInit (-924) and realigns the rest. Also fixes copies of the same wrong exec values, plus several wrong dos offsets, in api_call_identification.md and setfunction_patching.md. Checked against ADCD 2.1 References/Function.offs. V39 names in the exec table (CreatePool, CachePreDMA, AddMemHandler and so on) are left as they were, since they are more current than ADCD 2.0. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
c6f6253ea0
commit
ebb2dbeef7
4 changed files with 190 additions and 182 deletions
|
|
@ -53,7 +53,7 @@ APTR SetFunction(struct Library *library, LONG funcOffset, APTR newFunction);
|
|||
; Example: hook dos.library Write() at LVO -48
|
||||
|
||||
MOVEA.L _SysBase, A6
|
||||
JSR (-120,A6) ; Forbid() — prevent preemption during patch
|
||||
JSR (-132,A6) ; Forbid() — prevent preemption during patch
|
||||
|
||||
MOVEA.L _DOSBase, A1
|
||||
MOVE.L #-48, A0 ; LVO for Write
|
||||
|
|
@ -61,7 +61,7 @@ APTR SetFunction(struct Library *library, LONG funcOffset, APTR newFunction);
|
|||
JSR (-420,A6) ; SetFunction(DOSBase, -48, &my_write)
|
||||
MOVE.L D0, _orig_write ; save original function pointer
|
||||
|
||||
JSR (-126,A6) ; Permit()
|
||||
JSR (-138,A6) ; Permit()
|
||||
```
|
||||
|
||||
### C equivalent:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue