qt5base-lts/tests/auto
Thiago Macieira 4be50ecafd QTemporaryFile: fix issues with removing a file twice
The assertion in isUnnamedFile() we had was incorrect after the file was
removed, since we cleared the name and possibly reset back to the
template. Since ~QTemporaryFile() calls remove(), this was easy to
trigger if you attempted to remove the temp file and leave
QTemporaryFile like that.

Take this opportunity to add to the docs of setAutoRemove() explaining
the possibility of unnamed files.

#7  0x00007f69bcc2b50e in qt_assert (
    assertion=assertion@entry=0x7f69bcf194a0 "unnamedFile == d_func()->fileEntry.isEmpty()",
    file=file@entry=0x7f69bcf19458 "io/qtemporaryfile.cpp",
    line=line@entry=514) at global/qglobal.cpp:3123
#8  0x00007f69bcd672cf in QTemporaryFileEngine::isUnnamedFile (this=this@entry=0x55cd60644df0)
    at io/qtemporaryfile.cpp:514
#9  0x00007f69bcd683f7 in QTemporaryFileEngine::remove (this=0x55cd60644df0)
    at io/qtemporaryfile.cpp:396
#10 0x00007f69bcd48654 in QFile::remove (this=this@entry=0x7fffb393f7e0)
    at io/qfile.cpp:513
#11 0x00007f69bcd6653b in QTemporaryFile::~QTemporaryFile (this=0x7fffb393f7e0, __in_chrg=<optimized out>)
    at io/qtemporaryfile.cpp:719

Change-Id: I57a1bd6e0c194530b732fffd14f4ed28ca8185b2
Reviewed-by: Andreas Hartmetz <ahartmetz@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2017-11-23 05:27:23 +00:00
..
android
bic/data Update binary compatibility files for Qt 5.9.0 for QtBase 2017-08-14 13:48:17 +00:00
cmake tests: Unify license to GPL-EXCEPT 2017-04-03 07:18:46 +00:00
compilerwarnings/data
concurrent Change almost all other uses of qrand() to QRandomGenerator 2017-11-08 09:14:03 +00:00
corelib QTemporaryFile: fix issues with removing a file twice 2017-11-23 05:27:23 +00:00
dbus Use QSharedPointer::create() more 2017-07-19 13:40:42 +00:00
gui Change almost all other uses of qrand() to QRandomGenerator 2017-11-08 09:14:03 +00:00
guiapplauncher
installed_cmake
network Merge remote-tracking branch 'origin/5.9' into 5.10 2017-11-17 08:59:14 +01:00
opengl Change almost all other uses of qrand() to QRandomGenerator 2017-11-08 09:14:03 +00:00
other test: blacklist tst_QNetworkAccessManager_And_QProgressDialog::downloadCheck(with-zeroCopy) 2017-11-15 05:12:15 +00:00
printsupport Convert features.completer to QT_[REQUIRE_]CONFIG 2017-09-04 11:28:02 +00:00
shared Remove workaround for potentially unavailable pasteboard in macOS 2017-03-07 01:04:46 +00:00
sql Merge remote-tracking branch 'origin/5.9' into 5.10 2017-11-17 08:59:14 +01:00
testlib Make QCOMPARE print QColor alpha values on failure 2017-11-03 14:29:49 +00:00
tools Merge remote-tracking branch 'origin/5.9' into dev 2017-08-31 14:31:31 +02:00
widgets Merge remote-tracking branch 'origin/5.9' into 5.10 2017-11-17 08:59:14 +01:00
xml tst_qxmlsimplereader::inputFromSocket - fix race condition(s) 2017-11-06 19:14:41 +00:00
auto.pro Skip d-bus tests also on armv7 2017-11-04 18:42:36 +00:00
network-settings.h