Set up a process to be a shell using a startup packet.
Source position: amigados.pas line 2596
function CliInitNewcli( |
Dp: PDosPacket |
):LongInt; |
Dp |
|
startup arguments that were passed to the shell If NULL, defaults will be used |
Flags or a Pointer
This function initializes a process and CLI structure for a new shell, from parameters in an initial packet passed by the system (NewShell or NewCLI, etc). The format of the data in the packet is purposely not defined. The setup includes all the normal fields in the structures that are required for proper operation (current directory, paths, input streams, etc).
It returns a set of flags containing information about what type of shell invocation this is.
Definitions for the values of fn:
If Bit 31 is 0, then you must check IoErr() to determine if an error occurred. If IoErr() returns a pointer to your process, there has been an error, and you should clean up and exit. The packet will have already been returned by CliInitNewcli(). If it isn't a pointer to your process and Bit 31 is 0, reply the packet immediately. (Note: this is different from what you do for CliInitRun().)
This function is very similar to CliInitRun().
|
Set up a process to be a shell from initial packet |
|
|
Replies a packet to the person who sent it to you |
|
|
Waits for a packet to arrive at your pr_MsgPort |
|
|
Return extra information from the system |