Example xtsereq global user exit program – IBM SC33-1683-02 User Manual
Page 845

*=====================================================================*
* TS_REQUEST_COMPLETE - Invoked at XTSEREQC exit point
*
*
Free any shared storage that was acquired during previous
*
*
invocation at XTSEREQ.
*
*
*
* Registers:
*
*
R1 = Work register
*
*
R6 = Linkage register
*
*
R8 = Command Parameter List (CLPS)
*
*
*
* Logic:
*
*
TS_Request_Complete:
*
*
If called recursively then
*
*
call Error(Recursive_Call2)
*
*
Else
*
*
If the Command GROUP code is not a TS request then
*
*
call Error(Invalid_Group_Code2)
*
*
Else
*
*
If UEPTQTOK->token ¬= 0 then Call Freemain_Shared_Plist
*
*
End If
*
*
End If
*
*
Return
*
*=====================================================================*
TS_REQUEST_COMPLETE DS 0H
*
Check for possible recursion
L
R1,UEPRECUR
Address of recursive count
LH
R1,0(R1)
Fetch count
LTR
R1,R1
Has exit been invoked recursively?
BNZ
ERROR5
..Yes Branch to error routine
*
*
Check that the Command GROUP code corresponds to a TS request
L
R8,UEPCLPS
Fetch address of Command Plist
USING TS_ADDR_LIST,R8
Use R8 to address CLPS
L
R1,TS_ADDR0
Address the EID..
USING TS_EID,R1
..with Register 1
CLI
TS_GROUP,TS_TEMPSTOR_GROUP Is this a TS request?
BNE
ERROR6
..No Branch to error routine
DROP R1
Drop addressability to EID
DROP R8
Drop addressability to CLPS
*
L
R1,UEPTQTOK
Fetch address of Token
L
R1,0(R1)
Fetch actual token
LTR
R1,R1
Did XTSEREQ GETMAIN any storage?
BZ
RETURN
..No Return to caller
BAL
R6,FREEMAIN_SHARED ..Yes Issue FREEMAIN
B
RETURN
Return to caller
EJECT ,
*
Figure 113. Example exit program for the XTSEREQ exit (Part 7 of 16)
example XTSEREQ global user exit program
Appendix E. The example program for the XTSEREQ global user exit, DFH$XTSE
813