PKGBUILDs/aur/par2cmdline/09-Fixing-processing-of-the-first-file-parameter-the-ou.patch
2011-06-09 17:56:14 -04:00

20 lines
603 B
Diff

--- a/commandline.cpp
+++ b/commandline.cpp
@@ -539,7 +539,7 @@ bool CommandLine::Parse(int argc, char *argv[])
list<string> *filenames;
filenames = new list<string>;
- if (argv[0][0] == '-')
+ if (argv[0][0] == '-' && argv[0][1] == '\0')
{
while(true)
{
@@ -550,6 +550,8 @@ bool CommandLine::Parse(int argc, char *argv[])
break;
}
}
+ else
+ filenames->push_back(argv[0]);
list<string>::iterator fn = filenames->begin();
while (fn != filenames->end())