[Interest] QDateTime::toString() fails when used in exit handler

Thiago Macieira thiago.macieira at intel.com
Sat Jun 20 18:53:45 CEST 2020

On Friday, 19 June 2020 13:12:17 PDT Bernhard Lindner wrote:
> Can someone tell me what is going wrong here?

Yes, the calendar system in Qt has already been destroyed. You can't format 
dates anymore. QDateTime::date() and QDateTime::time() still work.

In general, don't do anything complex in exit handlers, since most global 
statics will have been destroyed already. SIOF: Static (De)Initialisation 
Order Fiasco.

Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel System Software Products

More information about the Interest mailing list