Stop using QTime as a timer in QIBaseDriver::close()

This is probably still the wrong thing to do here, though.

Change-Id: I4ff76393dde0b9ad9eb4a5e0d35fb6125d141901
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
This commit is contained in:
Shawn Rutledge 2019-10-02 22:28:06 +02:00
parent dcecaeb7b9
commit 85f9fa7fab

View File

@ -40,6 +40,7 @@
#include "qsql_ibase_p.h"
#include <qcoreapplication.h>
#include <qdatetime.h>
#include <qdeadlinetimer.h>
#include <qvariant.h>
#include <qsqlerror.h>
#include <qsqlfield.h>
@ -1570,10 +1571,9 @@ void QIBaseDriver::close()
d->eventBuffers.clear();
#if defined(FB_API_VER)
// Workaround for Firebird crash
QTime timer;
timer.start();
while (timer.elapsed() < 500)
// TODO check whether this workaround for Firebird crash is still needed
QDeadlineTimer timer(500);
while (!timer.hasExpired())
QCoreApplication::processEvents();
#endif
}