diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2018-01-26 10:40:04 +0100 |
---|---|---|
committer | Jan Mulder <jlmulder@xs4all.nl> | 2018-01-31 14:47:26 +0100 |
commit | 8f81a22e7f26729cc2f4902ba7db8f696314539f (patch) | |
tree | fada0afb75654a203016e7b24ec6d1677d0622f6 /core/dive.h | |
parent | f8f14c5edb43aafcc1d4c689af4a91d7274a4b82 (diff) | |
download | subsurface-8f81a22e7f26729cc2f4902ba7db8f696314539f.tar.gz |
Make report_error() reentrant
Remove the global error buffer and pass the error string directly
to the frontend. The frontend is then responsible for accumulating
errors.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/dive.h')
-rw-r--r-- | core/dive.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/dive.h b/core/dive.h index c155abbfd..3793cc359 100644 --- a/core/dive.h +++ b/core/dive.h @@ -719,7 +719,7 @@ extern "C" { extern int report_error(const char *fmt, ...); extern const char *get_error_string(void); -extern void set_error_cb(void(*cb)(void)); +extern void set_error_cb(void(*cb)(char *)); // Callback takes ownership of passed string extern struct dive *find_dive_including(timestamp_t when); extern bool dive_within_time_range(struct dive *dive, timestamp_t when, timestamp_t offset); |