summaryrefslogtreecommitdiffstats
path: root/core/structured_list.h
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2019-05-30 18:37:01 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-06-19 13:11:10 -0700
commit27d7f274094e5b1de01816610dedef154601c525 (patch)
tree620d861fe7ea86f2dc7387d6c727ac87fc8947f1 /core/structured_list.h
parent6200909ba4ffba2d79770b7eacdb615eeb2c88c1 (diff)
downloadsubsurface-27d7f274094e5b1de01816610dedef154601c525.tar.gz
Cleanup: fix comment to STRUCTURED_LIST_FREE
The comment said "Clear everything but the first element" but actually the macro freed the whole list including the first element. For dive computers it was explicitly called on the second element. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/structured_list.h')
-rw-r--r--core/structured_list.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/core/structured_list.h b/core/structured_list.h
index 232e4ee34..cdf76bb8e 100644
--- a/core/structured_list.h
+++ b/core/structured_list.h
@@ -2,8 +2,7 @@
#ifndef STRUCTURED_LIST_H
#define STRUCTURED_LIST_H
-/* Clear everything but the first element;
- * this works for taglist, picturelist, even dive computers */
+/* Clear whole list; this works for taglist, picturelist and dive computers */
#define STRUCTURED_LIST_FREE(_type, _start, _free) \
{ \
_type *_ptr = _start; \