Skip to content

Commit

Permalink
Stop using QTime as a timer in QIBaseDriver::close()
Browse files Browse the repository at this point in the history
This is probably still the wrong thing to do here, though.

Change-Id: I4ff76393dde0b9ad9eb4a5e0d35fb6125d141901
Reviewed-by: Edward Welbourne <[email protected]>
  • Loading branch information
ec1oud committed Oct 3, 2019
1 parent dcecaeb commit 85f9fa7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/plugins/sqldrivers/ibase/qsql_ibase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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>
Expand Down Expand Up @@ -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
}
Expand Down

0 comments on commit 85f9fa7

Please sign in to comment.