← Back to team overview

kicad-developers team mailing list archive

Re: [PATCH] SCH_LEGACY_PLUGIN::loadWire: fix parsing of wire color

 

Le 09/12/2018 à 20:10, Robert Abel a écrit :
> Hi Jean-Pierre,
> 
> On 09 Dec 2018 18:04, jp charras wrote:> Le 08/12/2018 à 22:38, Robert Abel a écrit :
>>> Wire color was parsed using parseInt alone.
>>> However, input contains a comma after every color component:
>>>  rgb(red, green, blue)
>>>
>>
>> However I committed a more basic patch.
> I thought about implementing it like in your patch as well.
> However, now you allow very ill-formatted inputs as well and still
> won't catch if parseInt doesn't work.
> 
> Consider rgb(5,,,   ,,,6,,,,   ;7)
> 
> No error message will be shown and blue will still be dropped.
> 
> Regards,
> 
> Robert
Hi Robert,
You are right, but the legacy parser is not a C compiler.
No need to test this kind of error: .sch files are expected to be .sch
files, ant nothing else.

-- 
Jean-Pierre CHARRAS


References