kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #09179
Re: Revision 3817 - netlist read and setvbuf
-
To:
kicad-developers@xxxxxxxxxxxxxxxxxxx
-
From:
Dick Hollenbeck <dick@xxxxxxxxxxx>
-
Date:
Mon, 26 Nov 2012 22:14:27 -0600
-
In-reply-to:
<CAH1+XAPoyY5j+YP6FiNXg_xf32USFBs8pTaMAs9e3=axVq+3CA@mail.gmail.com>
-
User-agent:
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0
On 11/26/2012 03:05 AM, Marco Serantoni wrote:
> I wish to discuss about my patch #3817, that comes to me from some signalations of
> problems in cvpcb and i've applied that is a probably a dirt workaround for a more deep
> problem that i wish to describe.
>
> The code parsing the netlist does more or less this:
>
> [Reads the header to identify the netlist type]
> [Rewind the stream]
> [Creates a FILE_LINE_READER]
> ----> calls setvbuf
> [Proceed to parse the file]
>
> Brian Woodcox, the person that has signalated to me the problem in cvpcb, has also
> hinted to me that reading the documentation, the setvbuf call should be not used after
> calls: http://www.cplusplus.com/reference/cstdio/setvbuf/.
> That seems that doesn't create problems in Linux/Windows with their current
> implementation but being formal this could be spot as an error.
>
> So I personally think that my "dirty hack" could be collapsed for all platforms, do you
> agree ?
No. The patch ends up not closing the file.
I have one in the works, which will fix it. But I will need more time to finish it. We
just had a holiday weekend here.
Thanks.
Dick
>
> Waiting for your feedbacks,
>
> --
> Marco
>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help : https://help.launchpad.net/ListHelp
References