Commit ba7cdf47 authored by Volker Krause's avatar Volker Krause
Browse files

Don't write invalid GPX time elements

parent 6c2f3486
......@@ -86,5 +86,7 @@ void Gpx::Writer::writeLink(const QString &href, const QString &text)
void Gpx::Writer::writeTime(const QDateTime &time)
{
m_writer.writeTextElement(QStringLiteral("time"), time.toString(Qt::ISODate));
if (time.isValid()) {
m_writer.writeTextElement(QStringLiteral("time"), time.toString(Qt::ISODate));
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment