BUG: Fix for network path argument parsing.
This commit is contained in:
parent
d720b2bc72
commit
185c82b6ad
|
@ -57,12 +57,23 @@ int CMakeCommandLineInfo::GetBoolValue(const CString& v) {
|
||||||
void CMakeCommandLineInfo::ParseParam(LPCTSTR lpszParam, BOOL bFlag, BOOL bLast)
|
void CMakeCommandLineInfo::ParseParam(LPCTSTR lpszParam, BOOL bFlag, BOOL bLast)
|
||||||
{
|
{
|
||||||
// Construct the full name of the argument.
|
// Construct the full name of the argument.
|
||||||
|
cmStdString param = lpszParam;
|
||||||
cmStdString value;
|
cmStdString value;
|
||||||
if(bFlag)
|
if(bFlag)
|
||||||
|
{
|
||||||
|
// Since bFlag is set, either a - or a / was removed from the
|
||||||
|
// parameter value. Assume it was a - unless the second character
|
||||||
|
// was a / which indicates a network path argument.
|
||||||
|
if(param.length() > 0 && param[0] == '/')
|
||||||
|
{
|
||||||
|
value = "/";
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
value = "-";
|
value = "-";
|
||||||
}
|
}
|
||||||
value += lpszParam;
|
}
|
||||||
|
value += param;
|
||||||
|
|
||||||
// Add the argument and reset the argv table in case strings were
|
// Add the argument and reset the argv table in case strings were
|
||||||
// moved.
|
// moved.
|
||||||
|
|
Loading…
Reference in New Issue