This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] sys.argv and ipython (interactive python) support in GDB/Python


>>>>> "Taisuke" == Taisuke Yamada <tai@rakugaki.org> writes:

Taisuke> So here is a patch to set sys.argv when initializing embedded
Taisuke> Python interpreter.

Taisuke> +  char *argv[] = { "gdb", NULL };

It seems to me that this should probably be { "", NULL }.
From the docs:

 -- Function: void PySys_SetArgvEx (intÂargc, charÂ**argv,
          intÂupdatepath)
[...]
       If there isn't a script that will be run,
     the first entry in _argv_ can be an empty string.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]