[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnash-dev] Tiny bug. Gnash does not allow character "=" in filename
From: |
Bastiaan Jacques |
Subject: |
Re: [Gnash-dev] Tiny bug. Gnash does not allow character "=" in filename. Patch included. |
Date: |
Sat, 15 Jul 2006 01:59:03 +0200 |
User-agent: |
KMail/1.9.3 |
On Friday 14 July 2006 23:07, annonygmouse wrote:
> I'm not sure if the patch is sane enough as I don't know what
> "variables, like ip=127.0.0.1" mean. But with only one argument
> the filename given is ignored, so I assume it is a filename that
> gnash should try to play.
Sounds reasonable to me.
Could you please create future patches available with diff -u?
> > dbglogfile.setVerbosity(2);
This looks like an unrelated change.
> 247c248,251
> < dbglogfile << "Got variable option on command line!" <<
> endl; ---
>
> > dbglogfile << "Got variable option on command line! " <<
> > endl; //Anyway, if there's only one parameter it may be a file with
> > a "=" in its name, so _there_ is a file. if ( argc==2 )
> > infile = argv[optind];
I think it would be cleaner to do this:
Index: gnash.cpp
===================================================================
RCS file: /sources/gnash/gnash/gui/gnash.cpp,v
retrieving revision 1.13
diff -u -r1.13 gnash.cpp
--- gnash.cpp 8 Jun 2006 16:11:14 -0000 1.13
+++ gnash.cpp 14 Jul 2006 23:54:05 -0000
@@ -243,7 +242,7 @@
// get the file name from the command line
while (optind < argc) {
// Some options set variables, like ip=127.0.0.1
- if (strchr(argv[optind], '=')) {
+ if (argc > 2 && strchr(argv[optind], '=')) {
dbglogfile << "Got variable option on command line!" << endl;
} else {
infile = argv[optind];
Would you agree?
Bastiaan