pyexiv2-developers team mailing list archive
-
pyexiv2-developers team
-
Mailing list archive
-
Message #00050
Re: Null bytes in strings
Hi Damon & all,
On 2010-06-04, Damon Lynch <damonlynch@xxxxxxxxx> wrote:
> Hi everyone,
>
> What is the best way for Pyexiv2 to handle Exif values that have Null
> bytes ('\x00') in the string value? They are problematic -- any strings
> containing them cannot be used as filenames, for instance.
>
> Should the raw_value, value or human_value have Null bytes automatically
> stripped, or should that decision be made by the calling application?
> Or should the utilities module have a "sanity checker" to examine the
> Exif values?
At the moment, decision of what to do is left to the calling
application, pyexiv2 doesn't apply any processing to string containing
Null bytes. I'm open to re-considering this behaviour though, provided
we have clear use-cases which would benefit from it.
Do you have examples of images with Exif values containing null bytes,
and do you know the reason for such values?
> Damon
Cheers,
Olivier
Follow ups
References