OSExecl / OSExecv

C Specification

#include <revolution/os.h>
void OSExecl(const char* dolfile, const char* arg0, .../*, (char*)NULL */);
void OSExecv(const char* dolfile, char* const argv[]);

Arguments

dolfile Path name for the file to be executed. If a null string is specified, the default dol file (the file booted by IPL) will be executed.
arg0,... This is a list of pointers to zero or more null-terminated strings that make up an argument list that can be used by the dol file to be executed (OSExecl() function only). The list of arguments must be terminated by a NULL pointer.
argv This is an array of pointers to zero or more null-terminated strings that make up an argument list that can be used by new programs (OSExecv() function only). The array of pointers must be terminated by a NULL pointer.

Return Values

None.

Description

A problem was found with OSExec; it has temporarily been removed from this release. It should be supported in the next patch or release.

OSExecl/OSExecv execute a new dol file. If successful, control is not returned to this function.

The initial argument for these functions is the full pathname of the dol file to execute. If a null string is specified, the default dol file that the IPL boots is executed.

If the specified dol file doesn't exist, an assert will fire in the debug library. In this case, control returns to this function immediately.

Arguments for OSExecl() are in the order of arg0, arg1, ..., argn. Together they describe a list of zero or more pointers to null-terminated strings that represent the argument list available to the new dol file. The list of arguments must be terminated by a NULL pointer.

OSExecv() provides an array of pointers to null-terminated strings that represent the argument list available to the new dol file. The array of pointers must be terminated by a NULL pointer.

OSSetSaveRegion also functions with OSExecl/OSExecv.

The Revolution Controllers will not be recalibrated during an execution sequence.

If the Game Disc cannot be read for any reason (including cover open, no disc, retry error, fatal error, wrong disk) during an execution sequence, OSExecl/OSExecv issue a hot reset. So if there is data not saved to the Memory Card, please make sure to save it before calling OSExecl/OSExecv (rather than passing the data using the save region feature).

An elf file can be converted to a dol file using makedol.

See Also

OSSetSaveRegion
OSIsRestart
makedol

Revision History

03/01/2006 Initial version.
06/19/2006 Temporarily deleted OSExec from this release.