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