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] Do not open Python scripts twice #2 [Re: [RFC] Crash sourcing Python script on Windows]


On Mon, Jan 23, 2012 at 2:17 PM, Jan Kratochvil
<jan.kratochvil@redhat.com> wrote:
> Hello Doug,
>
> On Mon, 23 Jan 2012 22:59:58 +0100, Doug Evans wrote:
>> Do you have any data that shows there is a problem with the double opening?
>
> Native GNU/Linux application would never double open files.

I dunno about "never", but I understand the gist of the point.

> It is the similar reason I disable GDB directories relocation in Fedora - as
> it is not a normal native application behavior - and in some corner cases it
> even breaks execution.

Huh.  Can you elaborate?

> GDB is still a bit exotic codebase nowadays, there is a long way to make it
> a normal application with codebase for easy contributions:
> ? ? ? ?http://sourceware.org/gdb/wiki/ProjectIdeas
> ? ? ? ? ? ? ? ?Here are some specific internal cleanups that are worth doing:

I don't understand how this is dispositive to this thread.

>> [I'm kinda uncomfortable with this patch, as is.]
>
> I am uncomfortable with code opening file by filename I have already an opened
> FILE * for, that is IMNSHO a clear bug.
>
> But sure if there is consensus it cannot be fixed in FSF GDB I can move the
> fix to Fedora GDB, there is now already ~50 to-be-merged patches.

Only 50?  It's getting better then.  1/2 :-)

btw, my main concern is the nature of the test on windows, and hoping
there is a better way to do this.

For reference sake, and I don't know if/when we'll switch to 3.x, or
support 2.x and 3.x, but Python 3.x uses fds not FILE*s.
[PyFile_FromFile is gone, and 3.x has PyFile_FromFd]


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