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
 

 

FETCH PROTECTED AREA error in Xpeditor

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
hiravibk
Warnings : 1

Active User


Joined: 14 Dec 2008
Posts: 103
Location: India

PostPosted: Mon Feb 10, 2014 12:46 pm    Post subject: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

HI All,

While trying to debug a subprogram,I am getting "FETCH PROTECTED AREA" message in the very first statement.

I have called a sub program dynamically by passing 2 variables which is of length 11 and 19 respectively. In the linkage section of the sub program, I have defined 2 variables of similar lengths 11 and 19 respectively and I have used procedure division using variable 1 and variable2. This resulted in the above error.

I have tried with declaring a s9(4) comp variable as the first variable in the linkage section of the sub program. Even in this case also I ended up with same error. Both the calling and called programs and batch. Can some one help me out in resolving this error?

Thanks in advance
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7228

PostPosted: Mon Feb 10, 2014 12:56 pm    Post subject: Reply to: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

Which debugger?

You need to show your code. Data definitions, CALL and PROCEDURE DIVISION.
Back to top
View user's profile Send private message
hiravibk
Warnings : 1

Active User


Joined: 14 Dec 2008
Posts: 103
Location: India

PostPosted: Tue Feb 11, 2014 10:11 am    Post subject: Reply to: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

DATA DEFINITION IN THE MAIN PROG:
01 P-IA.
05 NAME PIC X(11).
01 P-OA.
05 NAME PIC X(11).
05 DOB PIC X(8).


Call statement:

CALL WS-PROGRAM1 USING P-IA
P-OA
END-CALL



linkage section in the called program:
01 W-IA.
05 NAME PIC X(11).
01 W-OA.
05 NAME PIC X(11).
05 DOB PIC X(8).

PROCEDURE DIV in the called program:

PROCEDURE DIVISION USING W-IA, W-OA
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7228

PostPosted: Tue Feb 11, 2014 1:17 pm    Post subject: Reply to: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

Well, that looks OK.

You are trying to access storage which does not belong to you, and worse than the usual S0C4 you are trying to get it from an area which is protected from you "fetching" it.

If the program was running before, review the latest changes. If it is a new program, more difficult, but you have to do things like check all the parameters to any transfers of control and ensure they are in the correct order, if not using SSRANGE check all subscripting - something has overwritten something and is giving you bad addresses.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7228

PostPosted: Tue Feb 11, 2014 2:43 pm    Post subject: Reply to: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

I've never got a message like that, but never used Xpeditor. Perhaps it is just a S0C4? Same process, anyway.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Tue Feb 11, 2014 3:50 pm    Post subject: Reply to: FETCH PROTECTED AREA error in Xpeditor
Reply with quote

Are your DATA DIVISION fields part of an FD whose file hasn't been opened yet or are they defined to WORKING-STORAGE?
Back to top
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1238
Location: Richfield, MN, USA

PostPosted: Tue Feb 11, 2014 7:59 pm    Post subject:
Reply with quote

Double check to make sure you are executing the load module you THINK you are executing. Xpediter can be a bit tricky.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts S922 Error yuvan ABENDS & Debugging 3 Fri Dec 02, 2016 6:58 pm
No new posts Invoke Webservice Fails with DFHPI100... divated CICS 2 Thu Nov 24, 2016 5:57 pm
No new posts Error during restore rename archanamuthukrishnan All Other Mainframe Topics 2 Fri Oct 14, 2016 3:30 pm
No new posts Error IEC161I 052(009,XXXRS00)-084 wh... amitc23 JCL & VSAM 10 Wed Oct 12, 2016 5:00 pm
No new posts IDMS/DC-COBOL program - SNAP error wh... rakeshsekar1987 IDMS/ADSO 5 Tue Sep 13, 2016 8:28 pm


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