File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,9 @@ static string[] SplitArgs(string unsplitArgumentLine)
42
42
// ptrToSplitArgs is an array of pointers to null terminated Unicode strings.
43
43
// Copy each of these strings into our split argument array.
44
44
for ( int i = 0 ; i < numberOfArgs ; i ++ )
45
+ {
45
46
splitArgs [ i ] = Marshal . PtrToStringUni ( Marshal . ReadIntPtr ( ptrToSplitArgs , i * IntPtr . Size ) ) ;
47
+ }
46
48
47
49
return splitArgs ;
48
50
}
@@ -84,7 +86,6 @@ static string GetEscapedCommandLine()
84
86
85
87
public static ImportSettings Parse ( string [ ] args , string rootFolder )
86
88
{
87
-
88
89
ImportSettings importSettings = new ImportSettings ( ) ;
89
90
90
91
// if there are any errors, they are added to this list, then importing is aborted after parsing arguments
@@ -570,11 +571,15 @@ public static ImportSettings Parse(string[] args, string rootFolder)
570
571
break ;
571
572
572
573
default :
573
- errors . Add ( "Unrecognized option : " + cmd + argValueSeparator + param ) ;
574
+ errors . Add ( "Unrecognized argument : " + cmd + argValueSeparator + param ) ;
574
575
break ;
575
- }
576
+ } // switch
576
577
}
577
- }
578
+ else // bad arg (often due to missing "" around path with spaces)
579
+ {
580
+ errors . Add ( "Unknown argument: " + cmds [ 0 ] ) ;
581
+ }
582
+ } // for args
578
583
}
579
584
else // if no commandline args
580
585
{
You can’t perform that action at this time.
0 commit comments