From bdc470a80e0260011e3dfc4d949df8f9e222f73f Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Sun, 18 Feb 2018 16:22:34 +0100 Subject: Cleanup: Remove hash field from picture-structure The hash field in the picture-structure was in principle non-operational. It was set on loading, but never actually changed. The authoritative hash comes from the filename->hash map. Therefore, make this explicit by removing the hash field from the picture structure. Instead of filling the picture structure on loading, add the hash directly to the filename->hash map. This is done in the register_hash() function, which does not overwrite old entries. I.e. the local hash has priority over the save-file. This policy might be refined in the future. Signed-off-by: Berthold Stoeger --- core/dive.h | 1 - 1 file changed, 1 deletion(-) (limited to 'core/dive.h') diff --git a/core/dive.h b/core/dive.h index b152d59e9..56b0fbcfc 100644 --- a/core/dive.h +++ b/core/dive.h @@ -412,7 +412,6 @@ struct dive_components { /* picture list and methods related to dive picture handling */ struct picture { char *filename; - char *hash; offset_t offset; degrees_t latitude; degrees_t longitude; -- cgit v1.2.3-70-g09d2