user report_info() instead of qDebug in main() functions

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-03-25 20:33:30 +01:00 committed by bstoeger
parent 4af2ec88bd
commit 2c2ad1e5c9
3 changed files with 20 additions and 23 deletions

View file

@ -4,7 +4,6 @@
#include <QString>
#include <QCommandLineParser>
#include <QApplication>
#include <QDebug>
#include "core/qt-gui.h"
#include "core/qthelper.h"
@ -43,12 +42,12 @@ int main(int argc, char **argv)
QString output = parser.value(outputDirectoryOption);
if (source.isEmpty() || output.isEmpty()) {
qDebug() << "need --source and --output";
report_info("need --source and --output");
exit(1);
}
int ret = parse_file(qPrintable(source), &divelog);
if (ret) {
fprintf(stderr, "parse_file returned %d\n", ret);
report_info("parse_file returned %d", ret);
exit(1);
}