← Back to team overview

kicad-developers team mailing list archive

Re: [PATCH]fix library cache issue

 

Hi Damien,

wxString pointer’s operator== does a string compare, so you don’t need to convert m_library from a wxString pointer to a wxString.

The conversion is somewhat more expensive as it also copies the string.  Probably not really an issue here, but I’d still rather see the minimal change this late in the 5.0 release cycle.

Cheers,
Jeff.


> On 8 Jun 2018, at 21:04, Damien Espitallier <damien.espitallier@xxxxxxxxx> wrote:
> 
> Hi,
> 
> I found a bug with the library browser.
> 
> Step to reproduce:
>  - open Kicad
>  - open PCBNew
>  - click on Load footprint from library
>  - click on select by browser 
>  - select a library then quickly change to an another one 
> 
> => bug: the second category is selected but footprint list if for the first one.
> => bug2: selecting a footprint cause an assert: "/home/damien/prog/kicad-source-mirror/pcbnew/class_board.cpp(838): assert "Assert failure" failed in Add(): BOARD::Add() param error: aBoardItem NULL" 
> 
> 
> The attached patch fix the issue by checking the library name in addition to the library timestamp.
> 
> Damien Espitallier
> <0001-Do-not-use-only-timestamp-when-choosing-to-reload-or.patch>_______________________________________________
> 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