From e7ecb690ed2afa5475ec204a378b43b812b8305d Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sun, 8 Jun 2014 11:53:39 -0700 Subject: [PATCH] Picture handling: adjust timestamp after it's set We need to first parse the exif and then adjust the timestamp. Signed-off-by: Dirk Hohndel --- dive.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dive.c b/dive.c index 00c08ed2d..19be645b6 100644 --- a/dive.c +++ b/dive.c @@ -2275,10 +2275,10 @@ struct picture *alloc_picture() void dive_create_picture(struct dive *d, char *filename, int shift_time) { struct picture *p = alloc_picture(); - if (p->timestamp) - p->timestamp += shift_time; p->filename = filename; picture_load_exif_data(p); + if (p->timestamp) + p->timestamp += shift_time; dive_add_picture(d, p); dive_set_geodata_from_picture(d, p); }