MPE/iX Intrinsics Reference Manual (32650-90875)

Chapter 8 421
Command Definitions (HPMERGEEND-LOGSTATUS)
HPMYPROGRAM
HPMYPROGRAM
NM callable only.
Returns the file name of the program being executed by the calling process.
Syntax
CA I32 I32
HPMYPROGRAM(
formaldesig
,
status,length
CA I32 I32
myprogram
,
myprogram_length
,
myprogram_syntax
);
Parameters
formaldesig
character array (required)
Returns the fully qualified MPE syntax name of the program being
executed by the calling process.
The
formaldesig
parameter must be at least 28 bytes in length in order to
contain the longest possible MPE syntax file name with delimiters. The
lockword is not returned. The first and last characters of the returned
value are blanks that act as delimiters.
status
32-bit signed integer by reference (optional)
HPMYPROGRAM returns a NM Loader error 128 when the program name is
not represented using the syntax that the user specifies.
Returns the status of the HPMYPROGRAM intrinsic call. If no errors or
warnings are encountered,
status
returns 32 bits of zero. If errors or
warnings are encountered,
status
is interpreted as two 16-bit fields.
Bits (0:16) comprise
status.info
. A negative value indicates an error
condition, and a positive value indicates a warning condition. Refer to the
MPE/iX Error Message Manual Volumes 1, 2 and 3 for a description of its
value.
Bits (16:16) comprise
status.subsys
. The value represented by these bits
defines the subsystem that set the status information. The subsystem
identifier for HPMYPROGRAM is 104.
length
32-bit signed integer by reference (optional)
Returns the length (in bytes) of the file name returned in the
formaldesig
parameter (including the two blanks that act as delimiters). A zero
returned indicates that no file name is returned.
myprogram
character array (optional)
Returns the absolute pathname or fully qualified MPE syntax name of the
program being executed by the calling process.