CEEOEXEC replaces the prior POSIX process image with a new process
image for the executable file being run, supporting the POSIX 1003.1 exec() function.
Syntax
void
CEEOEXEC (
path_name_length,
path_name,
argument_count,
argument_length_list,
argument_list,
environment_count,
environment_data_length,
environment_data_list,
[
fc])
INT4 *path_name_length;
VSTRING *path_name;
INT4 *argument_count;
POINTER *argument_length_list;
POINTER *argument_list;
INT4 *environment_count;
POINTER *environment_data_length;
POINTER *environment_data_list;
FEEDBACK *fc;
- CEEOEXEC
- Call this CWI interface as follows:
L R15,CEECAACELV-CEECAA(,R12) CAA address is in R12
L R15,3288(,R15)
BALR R14,R15
- path_name_length (input)
- Specifies the name of a full word containing the length of the
path name of the file (program) to be run. The length can be up to
1023 bytes long.
- path_name (input)
- Specifies the name of a field of length file_name_length containing
the fully qualified path name of the file (program) to be run. Each
component of the path name can be up to 255 characters long. The complete
path name can be up to 1023 characters long and does not require a
terminating character.
- argument_count (input)
- Specifies the name of a full word containing a count of the number
of pointers in the argument_length_list and
the argument_list lists. If the program
needs no arguments, specify zero.
- argument_length_list (input)
- Specifies the address of the first in a list of pointers. Each
pointer in the list is the address of a full word giving the length
of one of the arguments to be passed to the specified program. If
the program needs no arguments, specify zero.
- argument_list (input)
- Specifies the address of a list of pointers. Each pointer in the
list is the address of a character string which is an argument to
be passed to the specified program. Each argument is of the length
specified by the corresponding element in the argument_length_list.
If the program needs no arguments, specify zero.
- environment_count (input)
- Specifies the name of a full word containing a count of the number
of pointers in the environment_data_length and
the environment_data_list lists. If the
program needs no arguments, specify zero.
- environment_data_length (input)
- Specifies the address of the first in a list of pointers. Each
pointer in the list is the address of a full word giving the length
of one of the environment variables to be passed to the specified
program. If the program does not use environment variables, specify
zero.
- environment_data_list (input)
- Specifies the address of a list of pointers. Each pointer in the
list is the address of a character string consisting of one of the
environment variables to be passed to the specified program. Each
environment list argument is of the length specified by the corresponding
element in the environment_length_list.
If the program does not use environment variables, specify zero.
- fc (output/optional)
- The parameter in which the CWI service feedback code is placed.
The following conditions can result from this CWI service.
Condition |
|
CEE000 |
Severity |
0 |
Msg_No |
0000 |
Message |
The service completed successfully. |
CEE4SA |
Severity |
3 |
Msg_No |
5002 |
Message |
POSIX function not available. z/OS UNIX System Services were
not started. |
CEE512 |
Severity |
3 |
Msg_No |
5154 |
Message |
The requested exec() failed
because it was invoked from a multithread environment. |
CEE519 |
Severity |
3 |
Msg_No |
5161 |
Message |
The z/OS UNIX callable
service BPX1EXC for the exec() function was
unsuccessful. The system return code was [return_code];
the reason code was [reason_code]. |
Qualifying Data: No. |
Name |
Input/ Output |
Type |
Value |
1 |
parm_count |
Input |
INT4 |
3 |
2 |
return_code |
Input |
INT4 |
Return code from kernel, BPX1EXC
function - nn
- Codes defined by ANSI C, POSIX, and z/OS UNIX
|
3 |
reason_code |
Input |
INT4 |
Reason code from kernel, BPX1EXC
function - nn
- Codes defined by ANSI C, POSIX, and z/OS UNIX
|
Usage notes: - Replaces the prior process image with a new process image for
the executable file being run.
- Target of exec() must be a C program and live
in the POSIX file system and POSIX(ON) runtime option must be present.
- Establishes an exit routine with the kernel, to gain
control after the kernel has validated the exec() and
prior to replacing the process image. In this exit routine, Language Environment drives
member languages for enclave termination.
- The values of the return_code and reason_code
are as defined in the z/OS UNIX System Services Programming: Assembler Callable Services Reference and
the OpenEdition for VM/ESA: Callable Services
Reference.
- This function is accessible independent of the POSIX runtime option.