You are on page 1of 1

DCL SPCPTR .

PARM1 PARM; DCL DD CONTROL CHAR(21) DCL DD TO-ADDRESS DCL DD FROM-ADDRESS DCL DD NBR-OF-BYTES DCL DD FEEDBACK

BAS(.PARM1); CHAR(8) DEF(CONTROL) CHAR(8) DEF(CONTROL) BIN(4) DEF(CONTROL) CHAR(1) DEF(CONTROL)

POS( 1); POS( 9); POS(17); POS(21);

DCL OL PARMS (.PARM1) EXT PARM MIN(1); DCL SPCPTR .ARG1 INIT(POINTER); DCL DD POINTER CHAR(16) BDRY(16); DCL SPCPTR .POINTER DEF(POINTER) POS(1); DCL DD PTR-TYPE CHAR(8) DEF(POINTER) POS(1); DCL DD PTR-ADDRESS CHAR(8) DEF(POINTER) POS(9); DCL SPCPTR .FROM; DCL DD FROM CHAR(256) BAS(.FROM); DCL SPCPTR .TO; DCL DD TO CHAR(256) BAS(.TO); DCL OL MIMAKPTR (.ARG1) ARG; DCL SYSPTR .MIMAKPTR; DCL DD RESOLVE CHAR(34); DCL DD RESOLVE-TYPE CHAR( 2) DEF(RESOLVE) POS( 1) INIT(X'0000'); DCL DD RESOLVE-NAME CHAR(30) DEF(RESOLVE) POS( 3); DCL DD RESOLVE-AUTH CHAR( 2) DEF(RESOLVE) POS(33) INIT(X'0000'); ENTRY * (PARMS) EXT; CPYBLA FEEDBACK, " "; CMPBLA(B) RESOLVE-TYPE, X'0000'/NEQ(COPY-DATA); RESOLVE-TO-PGM: CPYBLA RESOLVE-TYPE, X'0201'; CPYBLAP RESOLVE-NAME, "MIMAKPTR", " "; RSLVSP .MIMAKPTR, RESOLVE, *, *; COPY-DATA: CPYBLA CALLX CPYBWP CPYBLA CALLX CPYBWP CPYBWP RETURN: RTX PTR-ADDRESS, FROM-ADDRESS; .MIMAKPTR, MIMAKPTR, *; .FROM, .POINTER; PTR-ADDRESS, TO-ADDRESS; .MIMAKPTR, MIMAKPTR, *; .TO, .POINTER; TO(1:NBR-OF-BYTES), FROM(1:NBR-OF-BYTES); *;

DCL EXCM * EXCID(H'0000') BP(CANNOT-ACCESS) CV(X'00000000') IMD; CANNOT-ACCESS: CPYBLA FEEDBACK, "E"; B RETURN;