Page 1 of 1
S0C4 in a COBOL program
Posted: Wed Oct 06, 2010 11:40 pm
by Balr14
I have an Assembler program that does a LOAD and BASM to invoke a COBOL program. The COBOL program is abending with a S0C4 because it doesn't have variables from the Assembler program. The COBOL program is running in a different LE enclave. It seems to me, I have to figure out a way get the COBOL program to run in the same enclave as the Assembler program, or get those variables it's missing to it. Would CEEENTRY do this or is there a run-time LE parm that will handle it?
Re: S0C4 in a COBOL program
Posted: Thu Oct 07, 2010 3:57 am
by enrico-sorichetti
The COBOL program is abending with a S0C4 because it doesn't have variables from the Assembler program.
please explain better what You mean by ...
having variables
Re: S0C4 in a COBOL program
Posted: Thu Oct 07, 2010 4:07 am
by enrico-sorichetti
Re: S0C4 in a COBOL program
Posted: Thu Oct 07, 2010 7:10 pm
by Balr14
Thanks for the link. I'm going to give it a try. I think I have more problems with this program, but at least that eliminates one issue. This whole project is looking like a real dumb idea.
Re: S0C4 in a COBOL program
Posted: Thu Oct 07, 2010 7:40 pm
by Balr14
Sorry to be so vague. This is a 15 year old program I inherited that didn't work. I'm just trying it get it to work well enough to get an idea of exactly what it's trying to accomplish. Here is what I know so far:
The Assembler main module establishes a VSAM JRNL exit, then calls the COBOL program. The COBOL program issues several VSAM commands; the last one drives the JRNL exit. The JRNL exit returns to the COBOL program; the COBOL program fails on a subsequent VSAM command. The COBOL program is in a different enclave than the invoking Assembler program that established the JRNL exit. I don't know where the JRNL exit is.
I get a 400 line CEEDUMP from the COBOL program and the Assembler main keeps on running, so I haven't much to work with.
Re: S0C4 in a COBOL program
Posted: Fri Oct 08, 2010 1:26 am
by dick scherrer
Hello,
Did you try what i suggested elsewhere? Write a cobol "stub" that calls the assembler which then calls the other cobol.
By nesting, you may be able to keep everything in the same enclave. Might not, but it shouldn't take much work to try it.
Re: S0C4 in a COBOL program
Posted: Fri Oct 08, 2010 1:51 am
by Balr14
That was my next fix attempt. This relates to the topic I posted in the VSAM forum. It would be so easy to simply front-end VSAM with my own "VSAM" module at link edit time. But, I can't do that until I prove this way sucks.
Re: S0C4 in a COBOL program
Posted: Fri Oct 08, 2010 2:14 am
by dick scherrer
Hello,
Well, if we can't help fix it, we can (at least) commiserate
Good luck
d