Hi,

I have a problem with the BPX1EXM service, specifically with the STEPLIB it 
uses for the executed MVS program. My program (an LE program written in C, 
running under z/OS Unix) first forks a child process, which then immediately 
calls BPX1EXM (=execmvs) to start an MVS program in a specific load library.
According to the documentation of BPX1EXM, you can set the STEPLIB 
environment variable to the steplib you need the MVS program to have, and, in 
fact, this works up to a point. If I set the STEPLIB environment variable in 
the 
z/OS Unix shell before starting my program, then that STEPLIB value is used by 
BPX1EXM to find the program; that works fine.
BUT... if I use setenv() or putenv() or CEEENV() to set the same environment 
variable to the same value, then BPX1EXM does not seem to pick up this 
variable; it can't find the MVS program. It makes no difference where I put the 
putenv(), at the start of the program, before the fork, after the fork... it 
does 
not matter. Only if the variable is set in the shell before starting the 
program, 
then BPX1EXM picks it up. Obviously, that does not suit my needs, because I 
need to start multiple programs that reside in different load libraries.
Does anyone have an explanation for this behavior?

Thanks in advance,

Etienne

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to