| Last change
 on this file since 5314 was             5247, checked in by bird, 25 years ago | 
        
          | 
Calltable fixes. Handle event. New 14062e kernels.
 | 
        
          | File size:
            1.8 KB | 
      
      
| Line |  | 
|---|
| 1 | ; $Id: myldrOpenPatha.asm,v 1.5 2001-02-23 02:57:54 bird Exp $ | 
|---|
| 2 | ; | 
|---|
| 3 | ; myldrOpenPatha - assembly helpers for myldrOpenPath. | 
|---|
| 4 | ; | 
|---|
| 5 | ; Copyright (c) 2000 knut st. osmundsen | 
|---|
| 6 | ; | 
|---|
| 7 | ; Project Odin Software License can be found in LICENSE.TXT | 
|---|
| 8 | ; | 
|---|
| 9 | .386p | 
|---|
| 10 |  | 
|---|
| 11 | ; | 
|---|
| 12 | ; Include files | 
|---|
| 13 | ; | 
|---|
| 14 | include devsegdf.inc | 
|---|
| 15 | include options.inc | 
|---|
| 16 |  | 
|---|
| 17 | ; | 
|---|
| 18 | ; Exported symbols | 
|---|
| 19 | ; | 
|---|
| 20 | public _ldrOpenPath@20 | 
|---|
| 21 |  | 
|---|
| 22 | ; | 
|---|
| 23 | ; Externs | 
|---|
| 24 | ; | 
|---|
| 25 | extrn _ldrOpenPath_wrapped:PROC            ; calltab entry | 
|---|
| 26 | extrn _options:options | 
|---|
| 27 |  | 
|---|
| 28 |  | 
|---|
| 29 | CODE32 segment | 
|---|
| 30 | CODE32START label byte | 
|---|
| 31 |  | 
|---|
| 32 |  | 
|---|
| 33 | ;; | 
|---|
| 34 | ; Wrapper for ldrOpenPath which in build 14053 got a new parameter. | 
|---|
| 35 | ; @status    completely implemented. | 
|---|
| 36 | ; @author    knut st. osmundsen | 
|---|
| 37 | _ldrOpenPath@20 PROC NEAR | 
|---|
| 38 | ASSUME ds:FLAT | 
|---|
| 39 | cmp     FLAT:DATA16:_options.ulBuild, 14053 | 
|---|
| 40 | jge      new | 
|---|
| 41 |  | 
|---|
| 42 | if 0 | 
|---|
| 43 | ; | 
|---|
| 44 | ; We does now have one parameter more than necessary on the stack. | 
|---|
| 45 | ; | 
|---|
| 46 | add     esp, 4 | 
|---|
| 47 | mov     eax, [esp + 0ch] | 
|---|
| 48 | mov     [esp + 010h], eax | 
|---|
| 49 | mov     eax, [esp + 08h] | 
|---|
| 50 | mov     [esp +  0ch], eax | 
|---|
| 51 | mov     eax, [esp + 04h] | 
|---|
| 52 | mov     [esp +  08h], eax | 
|---|
| 53 | mov     eax, [esp + 00h] | 
|---|
| 54 | mov     [esp +  04h], eax | 
|---|
| 55 | mov     eax, [esp - 04h] | 
|---|
| 56 | mov     [esp +  00h], eax | 
|---|
| 57 | else | 
|---|
| 58 | ; | 
|---|
| 59 | ; Call without the last parameter | 
|---|
| 60 | ; | 
|---|
| 61 | push    dword ptr [esp + 10h] | 
|---|
| 62 | push    dword ptr [esp + 10h] | 
|---|
| 63 | push    dword ptr [esp + 10h] | 
|---|
| 64 | push    dword ptr [esp + 10h] | 
|---|
| 65 | call    _ldrOpenPath_wrapped | 
|---|
| 66 | ret     14h | 
|---|
| 67 | endif | 
|---|
| 68 |  | 
|---|
| 69 |  | 
|---|
| 70 | ; | 
|---|
| 71 | ; | 
|---|
| 72 | ; debug - clear the stack. | 
|---|
| 73 | ; | 
|---|
| 74 | if 0 | 
|---|
| 75 | extrn   pulTKSSBase32:DWORD | 
|---|
| 76 | push    ecx | 
|---|
| 77 | push    edi | 
|---|
| 78 | push    es | 
|---|
| 79 | push    ds | 
|---|
| 80 | pop     es | 
|---|
| 81 |  | 
|---|
| 82 | mov     edi, pulTKSSBase32 | 
|---|
| 83 | mov     edi, [edi] | 
|---|
| 84 | add     edi, esp | 
|---|
| 85 | mov     ecx, esp | 
|---|
| 86 | and     ecx, 0fffh | 
|---|
| 87 | sub     edi, ecx | 
|---|
| 88 | xor     eax, eax | 
|---|
| 89 | rep     stosb | 
|---|
| 90 |  | 
|---|
| 91 | pop     es | 
|---|
| 92 | pop     edi | 
|---|
| 93 | pop     ecx | 
|---|
| 94 | endif | 
|---|
| 95 |  | 
|---|
| 96 | new: | 
|---|
| 97 | jmp     _ldrOpenPath_wrapped | 
|---|
| 98 | _ldrOpenPath@20 ENDP | 
|---|
| 99 |  | 
|---|
| 100 |  | 
|---|
| 101 |  | 
|---|
| 102 | CODE32 ends | 
|---|
| 103 |  | 
|---|
| 104 | END | 
|---|
| 105 |  | 
|---|
| 106 |  | 
|---|
       
      
  Note:
 See   
TracBrowser
 for help on using the repository browser.