diff --git a/src/tcxparser.cpp b/src/tcxparser.cpp index f15734fc..f8ae8422 100644 --- a/src/tcxparser.cpp +++ b/src/tcxparser.cpp @@ -1,9 +1,9 @@ #include "tcxparser.h" -void TCXParser::warning(const char *text) +void TCXParser::warning(const char *text) const { - QFile *file = static_cast(_reader.device()); + const QFile *file = static_cast(_reader.device()); fprintf(stderr, "%s:%lld: %s\n", qPrintable(file->fileName()), _reader.lineNumber(), text); } diff --git a/src/tcxparser.h b/src/tcxparser.h index b11cb2c9..fa8cbb56 100644 --- a/src/tcxparser.h +++ b/src/tcxparser.h @@ -31,7 +31,7 @@ private: qreal number(); QDateTime time(); - void warning(const char *text); + void warning(const char *text) const; QXmlStreamReader _reader; };