Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

IRXINIT with RC=12

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
iqbal.mallick

New User


Joined: 13 Dec 2012
Posts: 14
Location: India

PostPosted: Mon Apr 07, 2014 1:19 pm    Post subject: IRXINIT with RC=12
Reply with quote

Hi I have a simple IRXINIT code to check the environment. The code is describled as below.

Code:
PGM1: PROC OPTIONS(MAIN);                                         
/* Function: DIsplay message from environment block */             
dcl sysnull builtin;                                               
dcl IRXINIT external options(RETCODE,ASSEMBLER,INTER);             
dcl 1 envblock based(addr_envb),                                   
      2 envblock_id char(8),                                       
      2 envblock_version char(4),                                 
      2 envblock_length fixed bin(31),                             
      2 envblock_parmblock ptr,                                   
      2 envblock_userfield ptr,                                   
      2 envblock_workblok_ext ptr,                                 
      2 envblock_irxexte ptr,                                     
      2 envblock_error,                                           
         3 error_call ptr,                                         
         3 rsvr fixed bin(31),                                     
         3 error_msgid char(8),                                   
         3 primary_error_message char(80),                         
         3 alternate_error_msg char(160);                         
dcl 1 addr_envb ptr;                                               
dcl 1 rc fixed bin(31);                                           
addr_envb = sysnull;                                               
fetch IRXINIT;                                                     
call IRXINIT('CHEKENVB','        ',0,0,0,ADDR_ENVB,RC);           
end PGM1;   


During execution the code is returning RC=12.

Through the below IBM reference table I came to know

Return code Description
0 The environment block address provided in register 0 is an environment on the current task.
4 The environment block address provided in register 0 is an environment on a parent task.
8 The environment block address provided in register 0 is an environment in the address space, but not on the current or a parent task.
12 The environment block address provided in register 0 was not found in the address space. Parameter 6 contains the address of the current, non-reentrant environment block.
24 The environment table could not be located. The environment block address provided in register 0 could not be checked.

I there any way to get a return code 0 from IRXINIT?
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Mon Apr 07, 2014 4:48 pm    Post subject: Reply to: IRXINIT with RC=12
Reply with quote

Quote:
I there any way to get a return code 0 from IRXINIT?


it depends on the address You passed to IRXINIT...
the explanation of the messages and codes manual seems pretty clear to me

for the IRXINIT check call the return code tells about the the existing environment
not about something being right or wrong!

the fact that You initialized the ENV pointer to null, makes it invalid by default!
Back to top
View user's profile Send private message
iqbal.mallick

New User


Joined: 13 Dec 2012
Posts: 14
Location: India

PostPosted: Mon Apr 07, 2014 5:14 pm    Post subject: IRXINIT with RC=12
Reply with quote

Thanks Enrico,

I believe I have lost my way. Just for a quick question from my side, I believe you can explain it better.

When I called IRXINIT with 'FINDENVB' function something like call
Code:
IRXINIT('FINDENVB','        ',0,0,0,ADDR_ENVB,RC);
with exactly the same code as above. It gives me a return of RC=28. Which seems to be successful but there is no current non-reentrant environment.

I did not understand this message There is no current non-reentrant environment. what is meant by non-reentrant environment? All I know is entrant and re-entrant program from CICS, but this is something different

I have just started going through IRXINIT? but I did not find any relevant meterials on IRXINIT and neither on IRXLOAD. So have just coding it by myself
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Mon Apr 07, 2014 5:21 pm    Post subject: Reply to: IRXINIT with RC=12
Reply with quote

see here for some pretty interesting documents

https://www.google.it/url?sa=t&rct=j&q=&esrc=s&source=web&cd=5&cad=rja&uact=8&ved=0CD8QFjAE&url=https%3A%2F%2Fshare.confex.com%2Fshare%2F116%2Fwebprogram%2FHandout%2FSession8834%2F8834%2520-%2520An%2520introduction%2520to%2520using%2520REXX%2520with%2520Language%2520Environment.pdf&ei=PZBCU46jDsb8ygO2z4GQCw&usg=AFQjCNHzR9_cPNx3PX0YAI2XrJRZwELf-A&sig2=dMxFVw5bUXEjkte9Z1fluw&bvm=bv.64125504,d.bGQ

and here
https://www.google.it/url?sa=t&rct=j&q=&esrc=s&source=web&cd=7&ved=0CEsQFjAG&url=https%3A%2F%2Fshare.confex.com%2Fshare%2F121%2Fwebprogram%2FHandout%2FSession13817%2F13817%2520-%2520An%2520Introduction%2520to%2520Using%2520REXX%2520with%2520Language%2520Environment.pdf&ei=PZBCU46jDsb8ygO2z4GQCw&usg=AFQjCNEz0iH7FQRiBo7BTkZYX1DBo359kQ&sig2=pbpLR0vvsOh6KtjaNQLSdA&bvm=bv.64125504,d.bGQ
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Mon Apr 07, 2014 5:22 pm    Post subject: Reply to: IRXINIT with RC=12
Reply with quote

Quote:
but there is no current non-reentrant environment.


unfortunately IRXINIT is not of the same opinion !

usually the environments are reentrant !
Back to top
View user's profile Send private message
iqbal.mallick

New User


Joined: 13 Dec 2012
Posts: 14
Location: India

PostPosted: Mon Apr 07, 2014 5:36 pm    Post subject:
Reply with quote

Thanks Enrico
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:



Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us