On Sun, Apr 14, 2013 at 6:35 PM, Ulrich Pegelow
<[email protected]> wrote:
> Am 14.04.2013 17:44, schrieb Pascal de Bruijn:
>> On Sun, Apr 14, 2013 at 5:24 PM, Ulrich Pegelow
>> <[email protected]> wrote:
>>> Am 12.04.2013 21:27, schrieb Pascal de Bruijn:
>>>>
>>>> Ulrich,
>>>>
>>>> Would you mind taking a look? Although my sample code seems to work,
>>>> I'm not sure what the best approach is to integrate it into lens.c
>>>
>>> Hi Pascal,
>>>
>>> attached is a revised version. The original code would copy the first
>>> space
>>> character in " or " to the output string which seems problematic.
>>
>> Ah thanks, I missed that indeed...
>>
>> The remaining question is where it should be integrated, as this
>> should only affect the lensname that is automatically provisioned to
>> the lensfun module...
>
> Depends if we want to have the sanitized code already stored in the lens
> module's parameter set or not.
>
> The easiest place would be line 824 in reload_defaults(). That's the place
> where we read the lens name from exif data. User would not see the trailing
> part " or xyz" of the string supplied by EXIV2.
>
> Alternatively we could keep the string as it is and put it into p->lens.
> Then we would sanitize when it comes to find the lens by name. Two places
> affected: line 721 in commit_params() and line 1627 in get_autoscale().

Right, well it think it most sense to have in our database whatever
Exiv2 feeds us... (In theory this problem could already exist with
current versions, I didn't check)...

So having the lens module itself sanitize the lens string itself seems
like the most robust approach.

Regards,
Pascal de Bruijn

------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter
_______________________________________________
darktable-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/darktable-devel

Reply via email to