ICELIB0.NLM → ICE_ParseCmdLine()
ICE_ParseCmdLine
- Description:
- Converts a user's command line parameters into a static array.
- Syntax for C:
- void *ICE_ParseCmdLine (
char *commandLineBuffer,
unsigned int flags
);
- Syntax for Assembly:
- Call ICE_ParseCmdLine C, offset commandLineBuffer, [flags]
- Parameters:
-
- commandLineBuffer
- (IN) Points to the null-terminated buffer or string to be parsed.
- flags
- (IN) Some rules to be enforced during parsing. All undocumented bit flags are considered reserved for future use, and should remain cleared (0) to ensure upward compatibility with newer versions of ICELIB0.NLM. Currently supported flags are as follows:
1 = Convert all commands to lower case (non-destructive)
2 = Don't convert TABs ("\t") to spaces
4 = Second through last elements will be delimited with spaces instead of NULLs so the remaining elements can be handled as a single string
16 = Enable colons (":") to be treated like spaces, but without omitting the colon
- Returns:
- Pointer to buffer (created by malloc()) that holds the static array of command line parameters, if not 0 or -1
0 = No buffer created
-1 = Not enough memory (malloc() failed)
- Remarks:
- Last pointer in array is NULL. If three parameters are processed, the resulting array will have four pointers and three elements, with the final pointer being NULL.
Remember to use NetWare's free() function when you no longer need the array.
- Resource files:
- icelib0.imp
- Minimum library version:
- 1.07