|
|
Given a command line (sub)string, find and parse its first argument. Parsing rules (see MS CRT): File names =========== Quoted string -> non-quoted string (quotes are not copied)
Regular argument ================ 2N backslashes + " -> N backslashes + begin/end quoted string (quote is not copied) 2N+1 backslashes + " -> N backslashes + literal " " + " in a quoted string -> single literal " all other combinations of symbols are copied as is
- Parameters:
-
| [in] | cmdPtr | pointer to the command line (sub)string |
| [in] | isFile | TRUE - use parsing rules for file name FALSE - use parsing rules for regular argument |
| [out] | buf | buffer that receives argument after parsing. If this parameter is NULL, the argument is not copied. If the buffer is too small, the terminating NULL is not copied into the buffer. |
| [in] | bufSize | size of the buffer; ignored if <buf> is NULL. |
| [out] | pArgSize | pointer to variable that receives size of the argument to be copied into the buffer, not including terminating NULL. If this parameter is NULL, the argument size is not returned. Otherwise, the size value is returned even if <buf> is NULL. |
| [out] | pNextPtr | pointer to variable that receives pointer to the command line substring following the found attribute. If this parameter is NULL, the pointer is not returned. |
- Returns:
- pointer to the first argument found in the specified command line (sub)string or NULL.
|