Skip to content

Make get_gps_info return data again even if altitude is unset

In version 0.12.1 and earlier, the gexiv2_metadata_get_gps_info function used to return TRUE if any of latitude, longitude, or altitude were available, even if not all three could be retrieved. In 0.12.2, the behaviour changed so that all three had to be present for the function to return TRUE. If even a single one is unset, FALSE is returned.

That change was made in f2d96b4d, but may have been unintentional. Empirically it appears that some tools will only set lat/long when drawing points on a map, without including an altitude.

This patch restores the older functionality such that if any of latitude, longitude, or altitude are available, gexiv2_metadata_get_gps_info and gexiv2_metadata_try_get_info return TRUE and pass back the available info.

Addresses #72 (closed)

Merge request reports