Mercurial > geeqie.yaz
comparison src/exif-common.c @ 1667:ece97f3f2305
fixes for a built without Exiv2
don't try to access XMP metadata if not compiled with Exiv2
some metadata options are valid without Exiv2, do not disable them
author | nadvornik |
---|---|
date | Tue, 30 Jun 2009 20:12:28 +0000 |
parents | 7cb24fdf07c0 |
children |
comparison
equal
deleted
inserted
replaced
1666:de25b265ab64 | 1667:ece97f3f2305 |
---|---|
617 | 617 |
618 if (file_cache_get(exif_cache, fd)) return fd->exif; | 618 if (file_cache_get(exif_cache, fd)) return fd->exif; |
619 | 619 |
620 /* CACHE_TYPE_XMP_METADATA file should exist only if the metadata are | 620 /* CACHE_TYPE_XMP_METADATA file should exist only if the metadata are |
621 * not writable directly, thus it should contain the most up-to-date version */ | 621 * not writable directly, thus it should contain the most up-to-date version */ |
622 sidecar_path = NULL; | |
623 | |
624 #ifdef HAVE_EXIV2 | |
625 /* we are not able to handle XMP sidecars without exiv2 */ | |
622 sidecar_path = cache_find_location(CACHE_TYPE_XMP_METADATA, fd->path); | 626 sidecar_path = cache_find_location(CACHE_TYPE_XMP_METADATA, fd->path); |
623 | 627 |
624 if (!sidecar_path) sidecar_path = file_data_get_sidecar_path(fd, TRUE); | 628 if (!sidecar_path) sidecar_path = file_data_get_sidecar_path(fd, TRUE); |
629 #endif | |
625 | 630 |
626 fd->exif = exif_read(fd->path, sidecar_path, fd->modified_xmp); | 631 fd->exif = exif_read(fd->path, sidecar_path, fd->modified_xmp); |
627 | 632 |
628 g_free(sidecar_path); | 633 g_free(sidecar_path); |
629 return fd->exif; | 634 return fd->exif; |