| 1 | <?php | 
|---|
| 2 |  | 
|---|
| 3 |  | 
|---|
| 4 | require "stilovi.php3"; | 
|---|
| 5 | require "Odin32DBHelpers.php3"; | 
|---|
| 6 |  | 
|---|
| 7 | $sTitle = "The Odin32 PE Loaders"; | 
|---|
| 8 |  | 
|---|
| 9 | require "01-PreTitle.php3"; | 
|---|
| 10 | echo $sTitle; | 
|---|
| 11 | require "02-PostTitle.php3"; | 
|---|
| 12 |  | 
|---|
| 13 | require "03-MainTableBeg.php3"; | 
|---|
| 14 | require "04-ColumnOne.php3"; | 
|---|
| 15 |  | 
|---|
| 16 | require "05-ColumnTwoHeader.php3"; | 
|---|
| 17 | echo $sTitle; | 
|---|
| 18 | require "06-ColumnTwoHeader2.php3"; | 
|---|
| 19 |  | 
|---|
| 20 |  | 
|---|
| 21 | /* | 
|---|
| 22 | * The article | 
|---|
| 23 | */ | 
|---|
| 24 |  | 
|---|
| 25 | echo " | 
|---|
| 26 | The story of the program being executed. | 
|---|
| 27 | "; | 
|---|
| 28 |  | 
|---|
| 29 | TekstBeg(); | 
|---|
| 30 | echo " | 
|---|
| 31 |  | 
|---|
| 32 | It all started when I typed the name of the program on an OS/2 commandline. | 
|---|
| 33 | This program was a not a native OS/2 program, as you might has thougth, but | 
|---|
| 34 | a Win32 program called SOL.EXE, or Solitaire. The first thing that happend | 
|---|
| 35 | was that the Shell, which in my case is 4OS/2, asks the Kernel what type of | 
|---|
| 36 | application this is. Some Programs are Presentation Manager programs, other | 
|---|
| 37 | are VIO (Virtual I/O) programs, while others again are pure full screen | 
|---|
| 38 | programs. So, 4OS/2 needs to know what kindred the program belongs to in | 
|---|
| 39 | order to start it in it's corrected environment. | 
|---|
| 40 | <p> | 
|---|
| 41 | DosQueryAppType is the name of the API telling which type a program has. | 
|---|
| 42 | This 32-bit call thunks to the 16-bit DosQAppType which does. DosQAppType | 
|---|
| 43 | checks if the specified programname has a path. If is has a (absolute) path | 
|---|
| 44 | nothing extra is done to find the file. But, if it hasn't the PATH is | 
|---|
| 45 | searched. If not found the .EXE extention is eventually (if not present) | 
|---|
| 46 | added to the filename and the PATH is researched. Then the Kernel is | 
|---|
| 47 | called, DOSIQAPPTYPE. DOSIQAPPTYPE does a farcall to w_QAppType which in | 
|---|
| 48 | turn thunks to the 32-bit loader function LDRQAppType. (Note that the | 
|---|
| 49 | LDR-prefix is in capital letters. This could be understood as this is an | 
|---|
| 50 | officially exported function from the Loader subsystem. | 
|---|
| 51 | <p> | 
|---|
| 52 |  | 
|---|
| 53 |  | 
|---|
| 54 |  | 
|---|
| 55 | "; | 
|---|
| 56 | TekstEnd(); | 
|---|
| 57 |  | 
|---|
| 58 |  | 
|---|
| 59 |  | 
|---|
| 60 |  | 
|---|
| 61 |  | 
|---|
| 62 | /* | 
|---|
| 63 | * Standard stuff. | 
|---|
| 64 | */ | 
|---|
| 65 |  | 
|---|
| 66 | require "07-ColumnTwoFooter.php3"; | 
|---|
| 67 | require "08-News.php3"; | 
|---|
| 68 | require "09-ContentsTitle.php3"; | 
|---|
| 69 |  | 
|---|
| 70 | Odin32DBWriteContents(); | 
|---|
| 71 |  | 
|---|
| 72 | require "10-EndOfContent.php3"; | 
|---|
| 73 | require "11-NetlabsContact.php3"; | 
|---|
| 74 |  | 
|---|
| 75 | $Kada=date ("j M Y", filemtime(__file__)); | 
|---|
| 76 | require "12-OdinBanner.php3"; | 
|---|
| 77 |  | 
|---|
| 78 | require "13-Closing.php3"; | 
|---|
| 79 |  | 
|---|
| 80 |  | 
|---|
| 81 |  | 
|---|
| 82 |  | 
|---|
| 83 | ?> | 
|---|