diff options
author | Anton Lundin <glance@acc.umu.se> | 2014-11-08 14:11:08 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-11-08 11:20:04 -0800 |
commit | 42d3ed0431c27b578f1e45832b0dbf3352aa96f5 (patch) | |
tree | aec3c1f935298417b72f03c17fe59faf73480fe2 /libdivecomputer.c | |
parent | a7a022d8db5790dc7e9d934e57465043e09667b8 (diff) | |
download | subsurface-42d3ed0431c27b578f1e45832b0dbf3352aa96f5.tar.gz |
Move calculate_string_hash into DC_FIELD_STRING
The calculate_string_hash is only used if DC_FIELD_STRING is defined, so
this removes a warning for everybody who doesn't build against a
libdivecomputer with DC_FIELD_STRING support.
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'libdivecomputer.c')
-rw-r--r-- | libdivecomputer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libdivecomputer.c b/libdivecomputer.c index 6974bccdf..67d291c16 100644 --- a/libdivecomputer.c +++ b/libdivecomputer.c @@ -397,12 +397,12 @@ static uint32_t calculate_diveid(const unsigned char *fingerprint, unsigned int return csum[0]; } +#ifdef DC_FIELD_STRING static uint32_t calculate_string_hash(const char *str) { return calculate_diveid(str, strlen(str)); } -#ifdef DC_FIELD_STRING static void parse_string_field(struct dive *dive, dc_field_string_t *str) { // Our dive ID is the string hash of the "Dive ID" string |