-------------------------------------------------------------------------------------- Helper function for command line retrieval. Updates strCmdLine and strFlag Example: if strCmdLine=="-width:1024 -forceref" then after: strCmdLine==" -forceref" and strFlag=="1024" --------------------------------------------------------------------------------------
| 425 | // then after: strCmdLine==" -forceref" and strFlag=="1024" |
| 426 | //-------------------------------------------------------------------------------------- |
| 427 | bool AMD::GetCmdParam( WCHAR*& strCmdLine, WCHAR* strFlag ) |
| 428 | { |
| 429 | if (*strCmdLine == L':' || *strCmdLine == L'=') |
| 430 | { |
| 431 | strCmdLine++; // Skip ':' |
| 432 | |
| 433 | // Place NULL terminator in strFlag after current token |
| 434 | wcscpy_s( strFlag, 256, strCmdLine ); |
| 435 | WCHAR* strSpace = strFlag; |
| 436 | while (*strSpace && (*strSpace > L' ')) |
| 437 | { |
| 438 | strSpace++; |
| 439 | } |
| 440 | *strSpace = 0; |
| 441 | |
| 442 | // Update strCmdLine |
| 443 | strCmdLine += wcslen( strFlag ); |
| 444 | return true; |
| 445 | } |
| 446 | else |
| 447 | { |
| 448 | strFlag[0] = 0; |
| 449 | return false; |
| 450 | } |
| 451 | } |
| 452 | |
| 453 | |
| 454 | //-------------------------------------------------------------------------------------- |
nothing calls this directly
no outgoing calls
no test coverage detected