diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2019-09-21 14:03:34 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-09-21 16:07:24 -0700 |
commit | fe7c0b30856d1286ea9a521ca9fb01e4952b6275 (patch) | |
tree | a4a184235f62e782d960df320ae07825d615a474 | |
parent | 9c48130d3717ca7e569bcf36fe753c90cc9dc3ea (diff) | |
download | subsurface-fe7c0b30856d1286ea9a521ca9fb01e4952b6275.tar.gz |
Cleanup: make location argument to put_location() const
Since this is an output function, the pointed-to value is not
modified.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
-rw-r--r-- | core/membuffer.c | 2 | ||||
-rw-r--r-- | core/membuffer.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/core/membuffer.c b/core/membuffer.c index 71832a428..548b70d45 100644 --- a/core/membuffer.c +++ b/core/membuffer.c @@ -218,7 +218,7 @@ void put_degrees(struct membuffer *b, degrees_t value, const char *pre, const ch put_format(b, "%s%s%u.%06u%s", pre, sign, FRACTION(udeg, 1000000), post); } -void put_location(struct membuffer *b, location_t *loc, const char *pre, const char *post) +void put_location(struct membuffer *b, const location_t *loc, const char *pre, const char *post) { if (has_location(loc)) { put_degrees(b, loc->lat, pre, " "); diff --git a/core/membuffer.h b/core/membuffer.h index a5f7d023d..03c42a61d 100644 --- a/core/membuffer.h +++ b/core/membuffer.h @@ -111,7 +111,7 @@ extern void put_duration(struct membuffer *, duration_t, const char *, const cha extern void put_pressure(struct membuffer *, pressure_t, const char *, const char *); extern void put_salinity(struct membuffer *, int, const char *, const char *); extern void put_degrees(struct membuffer *b, degrees_t value, const char *, const char *); -extern void put_location(struct membuffer *b, location_t *, const char *, const char *); +extern void put_location(struct membuffer *b, const location_t *, const char *, const char *); #ifdef __cplusplus } |