#93 Nikon Preview subdirectory discarded on rewrite

open
nobody
libexif (61)
5
2008-11-05
2008-11-05
Marcus Meissner
No

gthumb has:
http://bugzilla.gnome.org/show_bug.cgi?id=556994

a Nikon image with a Preview JPEG in a directory hidden inside the Nikon MakerNote directory.

When doing:
exif -t "User Comment" --set-value="foobar" xx.jpg

This Preview JPEG directory is gone, but the root pointer is still there. -> makernote preview is corrupted

$ exiftool xx.jpg|grep Preview
Preview Image Start : 10222
Preview Image Length : 23472
Preview Image : (Binary data 23472 bytes, use -b option to extract)
$ LANG=C exif -t "User Comment" --set-value="foobar" xx.jpg
Wrote file 'xx.jpg.modified.jpeg'.
$ exiftool xx.jpg.modified.jpeg|grep Preview
Warning : Bad NikonPreview directory

(I can't get exif --show-mnote to show this problem... might be a symptom.)

(image too large to attach, see attachment of:
http://bugzilla.gnome.org/show_bug.cgi?id=556994
)

Discussion