Make writeToAppLogFile() take an std::string parameter to avoid
an unnecessary UTF8->UTF16->UTF8 (std::string->QString->char *)
roundtrip.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
In commit 4de109bbf1, qDebug() was
replaced with report_info(). As a side effect, the subsurface log
messages are no longer redirected to the application log file. Only the
internal Qt logging ends up in the log file.
For bug reporting by end-users, this application log file is important
because it's the easiest way to collect all the necessary information to
investigate the problem.
Signed-off-by: Jef Driesen <jef@libdivecomputer.org>
This the C++ version of membuffer. Since everything is C++, it can
just be made the default.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Use the C++-version of membuffer.
This fixes two memory leaks: report_info() on every(!) invocation
and report_error() before the error callback is set.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>