home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 13 / AACD13.ISO / AACD / Resources / System / BoingBag1 / Contributions / Workbench / RexxArpLib3p6 / src / dispatch.a < prev    next >
Text File  |  1998-06-19  |  29KB  |  663 lines

  1. SAS AMIGA 680x0OBJ Module Disassembler 6.57
  2. Copyright © 1995 SAS Institute, Inc.
  3.  
  4.  
  5. Amiga Object File Loader V1.00
  6. 68000 Instruction Set
  7.  
  8. EXTERNAL DEFINITIONS
  9.  
  10. _RALDispatch 0000-00    @rxf_null 02F4-00    _ArpBase 0000-01    
  11. _AslBase 0004-01    _ScrSharBase 0008-01    _IntuitionBase 000C-01    
  12. _GfxBase 0010-01    _DiskfontBase 0014-01    _RexxSysBase 0018-01    
  13. _DOSBase 001C-01
  14.  
  15. SECTION 00 "text" 00000308 BYTES
  16. ;   1: /** Dispatch.c
  17. ;   2:  *
  18. ;   3:  *   DESCRIPTION:
  19. ;   4:  *   ===========
  20. ;   5:  *
  21. ;   6:  * This function is called as the "query" entry point from the
  22. ;   7:  * library.  The arguments are contained in a RexxMsg structure, which is
  23. ;   8:  * used as a parameter block and doesn't need to be unlinked from a port.
  24. ;   9:  * Dispatch() searches a table to see whether the requested function is
  25. ;  10:  * contained in this library and calls it if it is found.  The "query"
  26. ;  11:  * function should never alter the message packet, as it must be passed
  27. ;  12:  * along to other libraries until the function is found.
  28. ;  13:  *
  29. ;  14:  *       Arguments:
  30. ;  15:  * Up to 15 arguments may be passed in the rm_Args[] array of the parameter
  31. ;  16:  * block.  Arguments are ALWAYS passed as argstrings and can generally be
  32. ;  17:  * treated like string pointers in a 'C' program.  The called function may
  33. ;  18:  * need to convert the strings to numeric values if arithmetic operations
  34. ;  19:  * are to be performed.  A NULL value in the argument slot means that the
  35. ;  20:  * argument was omitted from the function call.
  36. ;  21:  *
  37. ;  22:  * The total number of arguments (including the defaulted ones) is available
  38. ;  23:  * in the low-order byte of the action code field rm_Action.
  39. ;  24:  * Note that REXX supports function calls with varying numbers of arguments,
  40. ;  25:  * and that the called function can always determine how many were actually
  41. ;  26:  * passed.
  42. ;  27:  *
  43. ;  28:  * Error reporting:
  44. ;  29:  * The function must return an integer error code and a result string if no
  45. ;  30:  * errors were detected.  Errors are considered to be ARexx internal error
  46. ;  31:  * codes, so the function should make use of these values as appropriate.
  47. ;  32:  * A code of 0 is interpreted to mean that everything worked.
  48. ;  33:  *
  49. ;  34:  * Result strings:
  50. ;  35:  * The result string must be returned as an argstring, a pointer to the
  51. ;  36:  * string buffer of an RexxArg structure.  Argstrings can be created by a
  52. ;  37:  * call to the ARexx Systems library function CreateArgstring().
  53. ;  38:  * N.B. Never allocate a result string if the error code is non-zero!
  54. ;  39:  *
  55. ;  40:  *   THIS VERSION:
  56. ;  41:  *   ============
  57. ;  42:  *
  58. ;  43:  * This version is written for Aztec C and implements a basic AmigaREXX
  59. ;  44:  * ARP library. It is based on the example library by Jim Mackraz who
  60. ;  45:  * got some stuff from Neil Katin, and the Dispatch() routine by Bill Hawes.
  61. ;  46:  * All changes and additions by me.
  62. ;  47:  *
  63. ;  48:  *   AUTHOR/DATE:  W.G.J. Langeveld, November 1987.
  64. ;  49:  *   ============
  65. ;  50:  *
  66. ;  51: **/
  67. ;  52: #include <functions.h>
  68. ;  53: #include "ralprotos.h"
  69. ;  54: #include <libraries/MyARP.h>
  70. ;  55: #include <intuition/intuitionbase.h>
  71. ;  56: #include <proto/rexxsyslib.h> // was rexxsys.h
  72. ;  57: #include <stdlib.h>
  73. ;  58: #include <string.h>
  74. ;  59: #include <ctype.h>
  75. ;  60: #include <simpreq.h>
  76. ;  61: #include "rexxarplib.h"
  77. ;  62: 
  78. ;  63: /*
  79. ;  64:  *   Library bases
  80. ;  65:  */
  81. ;  66: struct ArpBase       *ArpBase = NULL;
  82. ;  67: struct Library       *AslBase = NULL;
  83. ;  68: struct Library       *ScrSharBase = NULL;
  84. ;  69: struct IntuitionBase *IntuitionBase = NULL;
  85. ;  70: struct GfxBase       *GfxBase = NULL;
  86. ;  71: struct Library       *DiskfontBase = NULL;
  87. ;  72: struct Library        *RexxSysBase = NULL;
  88. ;  73: struct DosLibrary    *DOSBase = NULL;
  89. ;  74: 
  90. ;  75: #ifdef V35
  91. ;  76: #define BASEVER 36
  92. ;  77: #else
  93. ;  78: #define V36 (IntuitionBase->LibNode.lib_Version >= 36)
  94. ;  79: #define BASEVER 0
  95. ;  80: #endif
  96. ;  81:     
  97. ;  82: /*
  98. ;  83:  *   The function table
  99. ;  84:  */
  100. ;  85: static struct RXfunc rxfs[] = 
  101. ;  86: {
  102. ;  87:     {
  103. ;  88:         rxf_getfile,   "GETFILE"       , 11, 0       
  104. ;  89:     }
  105. ;  90:     ,
  106. ;  91:     {
  107. ;  92:         rxf_getsimp,   "REQUEST"       , 7 , 0       
  108. ;  93:     }
  109. ;  94:     ,
  110. ;  95:     {
  111. ;  96:         rxf_getenv,    "GETENV"        , 1 , 1       
  112. ;  97:     }
  113. ;  98:     ,
  114. ;  99:     {
  115. ; 100:         rxf_setenv,    "SETENV"        , 2 , 1       
  116. ; 101:     }
  117. ; 102:     ,
  118. ; 103:     {
  119. ; 104:         rxf_postmsg,   "POSTMSG"       , 4 , 0       
  120. ; 105:     }
  121. ; 106:     ,
  122. ; 107:     {
  123. ; 108:         rxf_stofront,  "SCREENTOFRONT" , 1 , 0       
  124. ; 109:     }
  125. ; 110:     ,
  126. ; 111:     {
  127. ; 112:         rxf_stoback,   "SCREENTOBACK"  , 1 , 0       
  128. ; 113:     }
  129. ; 114:     ,
  130. ; 115:     {
  131. ; 116:         rxf_srows,     "SCREENROWS"    , 1 , 0       
  132. ; 117:     }
  133. ; 118:     ,
  134. ; 119:     {
  135. ; 120:         rxf_scols,     "SCREENCOLS"    , 1 , 0       
  136. ; 121:     }
  137. ; 122:     ,
  138. ; 123:     {
  139. ; 124:         rxf_slace,     "SCREENLACE"    , 1 , 0       
  140. ; 125:     }
  141. ; 126:     ,
  142. ; 127:     {
  143. ; 128:         rxf_sopen,     "OPENSCREEN"    , 9 , 5       
  144. ; 129:     }
  145. ; 130:     ,
  146. ; 131:     {
  147. ; 132:         rxf_sclose,    "CLOSESCREEN"   , 1 , 1       
  148. ; 133:     }
  149. ; 134:     ,
  150. ; 135:     {
  151. ; 136:         rxf_sendp,     "SENDPARSED"    , 15, 1       
  152. ; 137:     }
  153. ; 138:     ,
  154. ; 139:     {
  155. ; 140:         rxf_createhost,"CREATEHOST"    , 3 , 2       
  156. ; 141:     }
  157. ; 142:     ,
  158. ; 143:     {
  159. ; 144:         rxf_filelist,  "FILELIST"      , 4 , 2       
  160. ; 145:     }
  161. ; 146:     ,
  162. ; 147:     {
  163. ; 148:         rxf_scolor,    "SCREENCOLOR"   , 5 , 2       
  164. ; 149:     }
  165. ; 150:     ,
  166. ; 151:     {
  167. ; 152:         rxf_showtitle, "SHOWTITLE"     , 2 , 2       
  168. ; 153:     }
  169. ; 154:     ,
  170. ; 155:     {
  171. ; 156:         rxf_getfont,   "GETFONT"       , 14, 0       
  172. ; 157:     }
  173. ; 158:     ,
  174. ; 159:     {
  175. ; 160:         rxf_smove,     "MOVESCREEN"    , 3 , 1       
  176. ; 161:     }
  177. ; 162:     ,
  178. ; 163:     {
  179. ; 164:         rxf_getlist,   "REQUESTLIST"   , 10, 3       
  180. ; 165:     }
  181. ; 166:     ,
  182. ; 167:     {
  183. ; 168:         rxf_null,          NULL        , 1 , 0       
  184. ; 169:     }
  185. ; 170: };
  186. ; 171: 
  187. ; 172: /**
  188. ; 173:  *
  189. ; 174:  *   The dispatcher.
  190. ; 175:  *
  191. ; 176: **/
  192. ; 177: long __stdargs __saveds RALDispatch(rmptr, resptr)
  193. ; 178:     struct RexxMsg *rmptr;
  194. ; 179:     char **resptr;
  195.        | 0000  514F                           SUBQ.W      #8,A7
  196.        | 0002  48E7 0F3E                      MOVEM.L     D4-D7/A2-A6,-(A7)
  197.        | 0006  266F 0034                      MOVEA.L     0034(A7),A3
  198.        | 000A  2A6F 0030                      MOVEA.L     0030(A7),A5
  199.        | 000E  49EE  0000-XX.2                LEA         _LinkerDB(A6),A4
  200. ; 180: {
  201. ; 181:     int nargs = 0, ival = 0, done = FALSE;
  202.        | 0012  7C00                           MOVEQ       #00,D6
  203. ; 182:     long result = 12L;
  204.        | 0014  700C                           MOVEQ       #0C,D0
  205.        | 0016  2F40 0028                      MOVE.L      D0,0028(A7)
  206. ; 183:     
  207. ; 184:     DOSBase = (struct DosLibrary *) OpenLibrary("dos.library", BASEVER);
  208.        | 001A  2F4E 0024                      MOVE.L      A6,0024(A7)
  209.        | 001E  43FA 028A                      LEA         028A(PC),A1
  210.        | 0022  7000                           MOVEQ       #00,D0
  211.        | 0024  2C78 0004                      MOVEA.L     0004,A6
  212.        | 0028  4EAE FDD8                      JSR         FDD8(A6)
  213.        | 002C  2940  001C-01.2                MOVE.L      D0,01.0000001C(A4)
  214. ; 185:     if (DOSBase == NULL)
  215.        | 0030  2C6F 0024                      MOVEA.L     0024(A7),A6
  216.        | 0034  6700 0118                      BEQ.W       014E
  217. ; 186:         goto cleanup;
  218. ; 187:     
  219. ; 188:     ArpBase = (struct ArpBase*) OpenLibrary("arp.library", 0L);
  220.        | 0038  43FA 027C                      LEA         027C(PC),A1
  221.        | 003C  7000                           MOVEQ       #00,D0
  222.        | 003E  2C78 0004                      MOVEA.L     0004,A6
  223.        | 0042  4EAE FDD8                      JSR         FDD8(A6)
  224.        | 0046  2940  0000-01.2                MOVE.L      D0,01.00000000(A4)
  225. ; 189:     if (ArpBase == NULL)
  226.        | 004A  2C6F 0024                      MOVEA.L     0024(A7),A6
  227.        | 004E  6700 00FE                      BEQ.W       014E
  228. ; 190:         goto cleanup;
  229. ; 191:     
  230. ; 192:     AslBase = OpenLibrary("asl.library", 0L);
  231.        | 0052  43FA 026E                      LEA         026E(PC),A1
  232.        | 0056  7000                           MOVEQ       #00,D0
  233.        | 0058  2C78 0004                      MOVEA.L     0004,A6
  234.        | 005C  4EAE FDD8                      JSR         FDD8(A6)
  235.        | 0060  2940  0004-01.2                MOVE.L      D0,01.00000004(A4)
  236. ; 193:     
  237. ; 194:     DiskfontBase = (struct Library *) OpenLibrary("diskfont.library", 0L);
  238.        | 0064  43FA 0268                      LEA         0268(PC),A1
  239.        | 0068  7000                           MOVEQ       #00,D0
  240.        | 006A  4EAE FDD8                      JSR         FDD8(A6)
  241.        | 006E  2940  0014-01.2                MOVE.L      D0,01.00000014(A4)
  242. ; 195:     
  243. ; 196:     RexxSysBase = OpenLibrary("rexxsyslib.library", 0L);
  244.        | 0072  43FA 026C                      LEA         026C(PC),A1
  245.        | 0076  7000                           MOVEQ       #00,D0
  246.        | 0078  4EAE FDD8                      JSR         FDD8(A6)
  247.        | 007C  2940  0018-01.2                MOVE.L      D0,01.00000018(A4)
  248. ; 197:     if (RexxSysBase == NULL)
  249.        | 0080  2C6F 0024                      MOVEA.L     0024(A7),A6
  250.        | 0084  6700 00C8                      BEQ.W       014E
  251. ; 198:         goto cleanup;
  252. ; 199:     
  253. ; 200:     if (!SReqOpenLibs())
  254.        | 0088  6100  0000-XX.1                BSR.W       @SReqOpenLibs
  255.        | 008C  4A40                           TST.W       D0
  256.        | 008E  6700 00BE                      BEQ.W       014E
  257. ; 201:         goto cleanup;
  258. ; 202: #ifdef V35
  259. ; 203:     /*
  260. ; 204:      *   V36 references IntuitionBase! so need to open Intuition first.
  261. ; 205:      */
  262. ; 206:     ScrSharBase = (struct Library *) OpenLibrary("screenshare.library", 0L);
  263. ; 207:     if ((ScrSharBase == NULL) && !V36)
  264. ; 208:         goto cleanup;
  265. ; 209: #endif
  266. ; 210:     
  267. ; 211:     
  268. ; 212:     result = 1L;
  269.        | 0092  7001                           MOVEQ       #01,D0
  270.        | 0094  2F40 0028                      MOVE.L      D0,0028(A7)
  271. ; 213:     *resptr = NULL;
  272.        | 0098  4293                           CLR.L       (A3)
  273. ; 214:     /*
  274. ; 215:      *   Get the number of provided arguments.
  275. ; 216:      */
  276. ; 217:     nargs = (rmptr->rm_Action) & 0xFF;
  277.        | 009A  7000                           MOVEQ       #00,D0
  278.        | 009C  4600                           NOT.B       D0
  279.        | 009E  C0AD 001C                      AND.L       001C(A5),D0
  280.        | 00A2  2A00                           MOVE.L      D0,D5
  281. ; 218:     /*
  282. ; 219:      *   Get the function index
  283. ; 220:      */
  284. ; 221:     ival = rxhtable_index(rmptr->rm_Args[0]);
  285.        | 00A4  206D 0028                      MOVEA.L     0028(A5),A0
  286.        | 00A8  6100  0000-XX.1                BSR.W       @rxhtable_index
  287.        | 00AC  3800                           MOVE.W      D0,D4
  288. ; 222:     if (ival >= 0) 
  289.        | 00AE  6D72                           BLT.B       0122
  290. ; 223:     {
  291. ; 224:         /*
  292. ; 225:          *   Got a regular function. Make sure it is an exact match.
  293. ; 226:          */
  294. ; 227:         if (strcmpu(rmptr->rm_Args[0], rxfs[ival].rexxname) == 0) 
  295.        | 00B0  48C4                           EXT.L       D4
  296.        | 00B2  2E04                           MOVE.L      D4,D7
  297.        | 00B4  DE87                           ADD.L       D7,D7
  298.        | 00B6  DE84                           ADD.L       D4,D7
  299.        | 00B8  E587                           ASL.L       #2,D7
  300.        | 00BA  45EC  0020-01.2                LEA         01.00000020(A4),A2
  301.        | 00BE  D5C7                           ADDA.L      D7,A2
  302.        | 00C0  206D 0028                      MOVEA.L     0028(A5),A0
  303.        | 00C4  226A 0004                      MOVEA.L     0004(A2),A1
  304.        | 00C8  6100  0000-XX.1                BSR.W       @strcmpu
  305.        | 00CC  4A40                           TST.W       D0
  306.        | 00CE  6652                           BNE.B       0122
  307. ; 228:         {
  308. ; 229:             result = 17L;
  309.        | 00D0  7011                           MOVEQ       #11,D0
  310.        | 00D2  2F40 0028                      MOVE.L      D0,0028(A7)
  311. ; 230:             /*
  312. ; 231:              *   Check number of arguments
  313. ; 232:              */
  314. ; 233:             if (nargs > rxfs[ival].nargs)
  315.        | 00D6  BA6A 0008                      CMP.W       0008(A2),D5
  316.        | 00DA  6E72                           BGT.B       014E
  317. ; 234:                 goto cleanup;
  318. ; 235:             if (nargs < rxfs[ival].nargs_req)
  319.        | 00DC  41EC  0020-01.2                LEA         01.00000020(A4),A0
  320.        | 00E0  BA70 780A                      CMP.W       0A(A0,D7.L),D5
  321.        | 00E4  6D68                           BLT.B       014E
  322. ; 236:                 goto cleanup;
  323. ; 237:             /*
  324. ; 238:              *   Call the function with the proper number of arguments.
  325. ; 239:              *   14 is 'filelist'. Sorry 'bout the kludge... ;^)
  326. ; 240:              *   17 is 'getfont'. Another kludge...
  327. ; 241:              *   19 is 'requestlist', Another kludge...
  328. ; 242:              */
  329. ; 243:             if (ival == 14 || ival == 0 || ival == 17 || ival == 19) 
  330.        | 00E6  700E                           MOVEQ       #0E,D0
  331.        | 00E8  B840                           CMP.W       D0,D4
  332.        | 00EA  6710                           BEQ.B       00FC
  333.        | 00EC  4A44                           TST.W       D4
  334.        | 00EE  670C                           BEQ.B       00FC
  335.        | 00F0  7011                           MOVEQ       #11,D0
  336.        | 00F2  B840                           CMP.W       D0,D4
  337.        | 00F4  6706                           BEQ.B       00FC
  338.        | 00F6  7013                           MOVEQ       #13,D0
  339.        | 00F8  B840                           CMP.W       D0,D4
  340.        | 00FA  660E                           BNE.B       010A
  341. ; 244:             {
  342. ; 245:                 *resptr = (*rxfs[ival].rexxfunc)(&result, nargs, (char **) rmptr);
  343.        | 00FC  2052                           MOVEA.L     (A2),A0
  344.        | 00FE  2208                           MOVE.L      A0,D1
  345.        | 0100  2005                           MOVE.L      D5,D0
  346.        | 0102  41EF 0028                      LEA         0028(A7),A0
  347.        | 0106  224D                           MOVEA.L     A5,A1
  348.        | 0108  600E                           BRA.B       0118
  349. ; 246:             }
  350. ; 247:             else
  351. ; 248:             {
  352. ; 249:                 *resptr = (*rxfs[ival].rexxfunc)(&result,
  353.        | 010A  2052                           MOVEA.L     (A2),A0
  354.        | 010C  43ED 002C                      LEA         002C(A5),A1
  355. ; 250:                 nargs, &(rmptr->rm_Args[1]));
  356.        | 0110  2208                           MOVE.L      A0,D1
  357.        | 0112  2005                           MOVE.L      D5,D0
  358.        | 0114  41EF 0028                      LEA         0028(A7),A0
  359.        | 0118  9288                           SUB.L       A0,D1
  360.        | 011A  4EB0 1800                      JSR         00(A0,D1.L)
  361.        | 011E  2680                           MOVE.L      D0,(A3)
  362. ; 251:             }
  363. ; 252:             done = TRUE;
  364.        | 0120  7C01                           MOVEQ       #01,D6
  365. ; 253:         }
  366. ; 254:     }
  367. ; 255:     
  368. ; 256:     if (!done) 
  369.        | 0122  4A46                           TST.W       D6
  370.        | 0124  6628                           BNE.B       014E
  371. ; 257:     {
  372. ; 258:         /*
  373. ; 259:          *   If not a regular function, see if this is a window host function
  374. ; 260:          */
  375. ; 261:         ival = whf_find(&result, nargs - 1, rmptr->rm_Args[0]);
  376.        | 0126  3005                           MOVE.W      D5,D0
  377.        | 0128  5340                           SUBQ.W      #1,D0
  378.        | 012A  41EF 0028                      LEA         0028(A7),A0
  379.        | 012E  226D 0028                      MOVEA.L     0028(A5),A1
  380.        | 0132  6100  0000-XX.1                BSR.W       @whf_find
  381. ; 262:         
  382. ; 263:         if (ival >= 0)
  383.        | 0136  4A40                           TST.W       D0
  384.        | 0138  6B14                           BMI.B       014E
  385. ; 264:             *resptr = whf_sendp(&result, nargs + 1, &(rmptr->rm_Args[0]));
  386.        | 013A  3005                           MOVE.W      D5,D0
  387.        | 013C  5240                           ADDQ.W      #1,D0
  388.        | 013E  41ED 0028                      LEA         0028(A5),A0
  389.        | 0142  2248                           MOVEA.L     A0,A1
  390.        | 0144  41EF 0028                      LEA         0028(A7),A0
  391.        | 0148  6100  0000-XX.1                BSR.W       @whf_sendp
  392.        | 014C  2680                           MOVE.L      D0,(A3)
  393. ; 265:     }
  394. ; 266:     
  395. ; 267:     cleanup:
  396. ; 268:     SReqCloseLibs();
  397.        | 014E  6100  0000-XX.1                BSR.W       @SReqCloseLibs
  398. ; 269:     if (RexxSysBase)
  399.        | 0152  202C  0018-01.2                MOVE.L      01.00000018(A4),D0
  400.        | 0156  670A                           BEQ.B       0162
  401. ; 270:         CloseLibrary( RexxSysBase );
  402.        | 0158  2240                           MOVEA.L     D0,A1
  403.        | 015A  2C78 0004                      MOVEA.L     0004,A6
  404.        | 015E  4EAE FE62                      JSR         FE62(A6)
  405.        | 0162  2C6F 0024                      MOVEA.L     0024(A7),A6
  406. ; 271:     if (ScrSharBase)
  407.        | 0166  202C  0008-01.2                MOVE.L      01.00000008(A4),D0
  408.        | 016A  670A                           BEQ.B       0176
  409. ; 272:         CloseLibrary( ScrSharBase );
  410.        | 016C  2240                           MOVEA.L     D0,A1
  411.        | 016E  2C78 0004                      MOVEA.L     0004,A6
  412.        | 0172  4EAE FE62                      JSR         FE62(A6)
  413.        | 0176  2C6F 0024                      MOVEA.L     0024(A7),A6
  414. ; 273:     if (DiskfontBase)
  415.        | 017A  202C  0014-01.2                MOVE.L      01.00000014(A4),D0
  416.        | 017E  670A                           BEQ.B       018A
  417. ; 274:         CloseLibrary( DiskfontBase );
  418.        | 0180  2240                           MOVEA.L     D0,A1
  419.        | 0182  2C78 0004                      MOVEA.L     0004,A6
  420.        | 0186  4EAE FE62                      JSR         FE62(A6)
  421.        | 018A  2C6F 0024                      MOVEA.L     0024(A7),A6
  422. ; 275:     if (ArpBase)
  423.        | 018E  202C  0000-01.2                MOVE.L      01.00000000(A4),D0
  424.        | 0192  670A                           BEQ.B       019E
  425. ; 276:         CloseLibrary( ( struct Library * ) ArpBase );
  426.        | 0194  2240                           MOVEA.L     D0,A1
  427.        | 0196  2C78 0004                      MOVEA.L     0004,A6
  428.        | 019A  4EAE FE62                      JSR         FE62(A6)
  429.        | 019E  2C6F 0024                      MOVEA.L     0024(A7),A6
  430. ; 277:     if (AslBase)
  431.        | 01A2  202C  0004-01.2                MOVE.L      01.00000004(A4),D0
  432.        | 01A6  670A                           BEQ.B       01B2
  433. ; 278:         CloseLibrary( AslBase );
  434.        | 01A8  2240                           MOVEA.L     D0,A1
  435.        | 01AA  2C78 0004                      MOVEA.L     0004,A6
  436.        | 01AE  4EAE FE62                      JSR         FE62(A6)
  437.        | 01B2  2C6F 0024                      MOVEA.L     0024(A7),A6
  438. ; 279:     if (DOSBase)
  439.        | 01B6  202C  001C-01.2                MOVE.L      01.0000001C(A4),D0
  440.        | 01BA  670A                           BEQ.B       01C6
  441. ; 280:         CloseLibrary( ( struct Library * ) DOSBase );
  442.        | 01BC  2240                           MOVEA.L     D0,A1
  443.        | 01BE  2C78 0004                      MOVEA.L     0004,A6
  444.        | 01C2  4EAE FE62                      JSR         FE62(A6)
  445. ; 281:     
  446. ; 282:     return(result);
  447.        | 01C6  202F 0028                      MOVE.L      0028(A7),D0
  448.        | 01CA  4CDF 7CF0                      MOVEM.L     (A7)+,D4-D7/A2-A6
  449.        | 01CE  504F                           ADDQ.W      #8,A7
  450.        | 01D0  4E75                           RTS
  451.        | 01D2  4745                           
  452.        | 01D4  5446                           ADDQ.W      #2,D6
  453.        | 01D6  494C                           PEA         A4
  454.        | 01D8  4500                           CHK.L       D0,D2
  455.        | 01DA  5245                           ADDQ.W      #1,D5
  456.        | 01DC  5155                           SUBQ.W      #8,(A5)
  457.        | 01DE  4553                           
  458.        | 01E0  5400                           ADDQ.B      #2,D0
  459.        | 01E2  4745                           
  460.        | 01E4  5445                           ADDQ.W      #2,D5
  461.        | 01E6  4E56 0000                      LINK        A6,#0000
  462.        | 01EA  5345                           SUBQ.W      #1,D5
  463.        | 01EC  5445                           ADDQ.W      #2,D5
  464.        | 01EE  4E56 0000                      LINK        A6,#0000
  465.        | 01F2  504F                           ADDQ.W      #8,A7
  466.        | 01F4  5354                           SUBQ.W      #1,(A4)
  467.        | 01F6  4D53                           PEA         (A3)
  468.        | 01F8  4700                           CHK.L       D0,D3
  469.        | 01FA  5343                           SUBQ.W      #1,D3
  470.        | 01FC  5245                           ADDQ.W      #1,D5
  471.        | 01FE  454E                           
  472.        | 0200  544F                           ADDQ.W      #2,A7
  473.        | 0202  4652                           NOT.W       (A2)
  474.        | 0204  4F4E                           TRAP        #0E
  475.        | 0206  5400                           ADDQ.B      #2,D0
  476.        | 0208  5343                           SUBQ.W      #1,D3
  477.        | 020A  5245                           ADDQ.W      #1,D5
  478.        | 020C  454E                           
  479.        | 020E  544F                           ADDQ.W      #2,A7
  480.        | 0210  4241                           CLR.W       D1
  481.        | 0212  434B                           
  482.        | 0214  0000 5343                      ORI.B       #43,D0
  483.        | 0218  5245                           ADDQ.W      #1,D5
  484.        | 021A  454E                           
  485.        | 021C  524F                           ADDQ.W      #1,A7
  486.        | 021E  5753                           SUBQ.W      #3,(A3)
  487.        | 0220  0000 5343                      ORI.B       #43,D0
  488.        | 0224  5245                           ADDQ.W      #1,D5
  489.        | 0226  454E                           
  490.        | 0228  434F                           
  491.        | 022A  4C53 0000                      DIVU.L      (A3),D0
  492.        | 022E  5343                           SUBQ.W      #1,D3
  493.        | 0230  5245                           ADDQ.W      #1,D5
  494.        | 0232  454E                           
  495.        | 0234  4C41 4345                      DIVUL.L     D1,D5:D4
  496.        | 0238  0000 4F50                      ORI.B       #50,D0
  497.        | 023C  454E                           
  498.        | 023E  5343                           SUBQ.W      #1,D3
  499.        | 0240  5245                           ADDQ.W      #1,D5
  500.        | 0242  454E                           
  501.        | 0244  0000 434C                      ORI.B       #4C,D0
  502.        | 0248  4F53 4553                      LINK        A3,#4553
  503.        | 024C  4352                           
  504.        | 024E  4545                           
  505.        | 0250  4E00                           TRAP        #00
  506.        | 0252  5345                           SUBQ.W      #1,D5
  507.        | 0254  4E44                           TRAP        #04
  508.        | 0256  5041                           ADDQ.W      #8,D1
  509.        | 0258  5253                           ADDQ.W      #1,(A3)
  510.        | 025A  4544                           
  511.        | 025C  0000 4352                      ORI.B       #52,D0
  512.        | 0260  4541                           
  513.        | 0262  5445                           ADDQ.W      #2,D5
  514.        | 0264  484F                           BKPT        #7
  515.        | 0266  5354                           SUBQ.W      #1,(A4)
  516.        | 0268  0000 4649                      ORI.B       #49,D0
  517.        | 026C  4C45 4C49                      DIVS.L      D5,D1:D4
  518.        | 0270  5354                           SUBQ.W      #1,(A4)
  519.        | 0272  0000 5343                      ORI.B       #43,D0
  520.        | 0276  5245                           ADDQ.W      #1,D5
  521.        | 0278  454E                           
  522.        | 027A  434F                           
  523.        | 027C  4C4F 5200                      DIVUL.L     A7,D0:D5
  524.        | 0280  5348                           SUBQ.W      #1,A0
  525.        | 0282  4F57 5449                      LINK        A7,#5449
  526.        | 0286  544C                           ADDQ.W      #2,A4
  527.        | 0288  4500                           CHK.L       D0,D2
  528.        | 028A  4745                           
  529.        | 028C  5446                           ADDQ.W      #2,D6
  530.        | 028E  4F4E                           TRAP        #0E
  531.        | 0290  5400                           ADDQ.B      #2,D0
  532.        | 0292  4D4F                           PEA         A7
  533.        | 0294  5645                           ADDQ.W      #3,D5
  534.        | 0296  5343                           SUBQ.W      #1,D3
  535.        | 0298  5245                           ADDQ.W      #1,D5
  536.        | 029A  454E                           
  537.        | 029C  0000 5245                      ORI.B       #45,D0
  538.        | 02A0  5155                           SUBQ.W      #8,(A5)
  539.        | 02A2  4553                           
  540.        | 02A4  544C                           ADDQ.W      #2,A4
  541.        | 02A6  4953                           PEA         (A3)
  542.        | 02A8  5400                           ADDQ.B      #2,D0
  543.        | 02AA  646F                           BCC.B       031B
  544.        | 02AC  732E                           
  545.        | 02AE  6C69                           BGE.B       0319
  546.        | 02B0  6272                           BHI.B       0324
  547.        | 02B2  6172                           BSR.B       0326
  548.        | 02B4  7900                           
  549.        | 02B6  6172                           BSR.B       032A
  550.        | 02B8  702E                           MOVEQ       #2E,D0
  551.        | 02BA  6C69                           BGE.B       0325
  552.        | 02BC  6272                           BHI.B       0330
  553.        | 02BE  6172                           BSR.B       0332
  554.        | 02C0  7900                           
  555.        | 02C2  6173                           BSR.B       0337
  556.        | 02C4  6C2E                           BGE.B       02F4
  557.        | 02C6  6C69                           BGE.B       0331
  558.        | 02C8  6272                           BHI.B       033C
  559.        | 02CA  6172                           BSR.B       033E
  560.        | 02CC  7900                           
  561.        | 02CE  6469                           BCC.B       0339
  562.        | 02D0  736B                           
  563.        | 02D2  666F                           BNE.B       0343
  564.        | 02D4  6E74                           BGT.B       034A
  565.        | 02D6  2E6C 6962                      MOVEA.L     6962(A4),A7
  566.        | 02DA  7261                           MOVEQ       #61,D1
  567.        | 02DC  7279                           MOVEQ       #79,D1
  568.        | 02DE  0000 7265                      ORI.B       #65,D0
  569.        | 02E2  7878                           MOVEQ       #78,D4
  570.        | 02E4  7379                           
  571.        | 02E6  736C                           
  572.        | 02E8  6962                           BVS.B       034C
  573.        | 02EA  2E6C 6962                      MOVEA.L     6962(A4),A7
  574.        | 02EE  7261                           MOVEQ       #61,D1
  575.        | 02F0  7279                           MOVEQ       #79,D1
  576.        | 02F2  0000 9EFC                      ORI.B       #FC,D0
  577. ; 283: }
  578. ; 284: 
  579. ; 285: 
  580. ; 286: /**
  581. ; 287:  *
  582. ; 288:  *   The null function
  583. ; 289:  *
  584. ; 290: **/
  585. ; 291: char *rxf_null(err, n, dummy)
  586. ; 292:     long *err;
  587. ; 293:     int n;
  588. ; 294:     char **dummy;
  589.        | 02F6  000C 48D7                      ORI.B       #D7,A4
  590.        | 02FA  0201 7015                      ANDI.B      #15,D1
  591. ; 295: {
  592. ; 296:     *err = 21L;
  593.        | 02FE  2080                           MOVE.L      D0,(A0)
  594. ; 297:     return(0L);
  595.        | 0300  7000                           MOVEQ       #00,D0
  596.        | 0302  DEFC 000C                      ADDA.W      #000C,A7
  597.        | 0306  4E75                           RTS
  598.  
  599. SECTION 01 "__MERGED" 0000011C BYTES
  600. OFFSETS 0000 THROUGH 001F CONTAIN ZERO
  601. 0020 00000000-XX @rxf_getfile
  602. 0024 000001D2-00 00.000001D2
  603. 0028 00 0B 00 00 ....
  604. 002C 00000000-XX @rxf_getsimp
  605. 0030 000001DA-00 00.000001DA
  606. 0034 00 07 00 00 ....
  607. 0038 00000000-XX @rxf_getenv
  608. 003C 000001E2-00 00.000001E2
  609. 0040 00 01 00 01 ....
  610. 0044 00000000-XX @rxf_setenv
  611. 0048 000001EA-00 00.000001EA
  612. 004C 00 02 00 01 ....
  613. 0050 00000000-XX @rxf_postmsg
  614. 0054 000001F2-00 00.000001F2
  615. 0058 00 04 00 00 ....
  616. 005C 00000000-XX @rxf_stofront
  617. 0060 000001FA-00 00.000001FA
  618. 0064 00 01 00 00 ....
  619. 0068 00000000-XX @rxf_stoback
  620. 006C 00000208-00 00.00000208
  621. 0070 00 01 00 00 ....
  622. 0074 00000000-XX @rxf_srows
  623. 0078 00000216-00 00.00000216
  624. 007C 00 01 00 00 ....
  625. 0080 00000000-XX @rxf_scols
  626. 0084 00000222-00 00.00000222
  627. 0088 00 01 00 00 ....
  628. 008C 00000000-XX @rxf_slace
  629. 0090 0000022E-00 00.0000022E
  630. 0094 00 01 00 00 ....
  631. 0098 00000000-XX @rxf_sopen
  632. 009C 0000023A-00 00.0000023A
  633. 00A0 00 09 00 05 ....
  634. 00A4 00000000-XX @rxf_sclose
  635. 00A8 00000246-00 00.00000246
  636. 00AC 00 01 00 01 ....
  637. 00B0 00000000-XX @rxf_sendp
  638. 00B4 00000252-00 00.00000252
  639. 00B8 00 0F 00 01 ....
  640. 00BC 00000000-XX @rxf_createhost
  641. 00C0 0000025E-00 00.0000025E
  642. 00C4 00 03 00 02 ....
  643. 00C8 00000000-XX @rxf_filelist
  644. 00CC 0000026A-00 00.0000026A
  645. 00D0 00 04 00 02 ....
  646. 00D4 00000000-XX @rxf_scolor
  647. 00D8 00000274-00 00.00000274
  648. 00DC 00 05 00 02 ....
  649. 00E0 00000000-XX @rxf_showtitle
  650. 00E4 00000280-00 00.00000280
  651. 00E8 00 02 00 02 ....
  652. 00EC 00000000-XX @rxf_getfont
  653. 00F0 0000028A-00 00.0000028A
  654. 00F4 00 0E 00 00 ....
  655. 00F8 00000000-XX @rxf_smove
  656. 00FC 00000292-00 00.00000292
  657. 0100 00 03 00 01 ....
  658. 0104 00000000-XX @rxf_getlist
  659. 0108 0000029E-00 00.0000029E
  660. 010C 00 0A 00 03 ....
  661. 0110 000002F4-00 00.000002F4
  662. 0114 00 00 00 00 00 01 00 00 80 47 00 04 .........G..
  663.