was merged, QTemporaryFile::rename fails on Linux 4.10+ due to this kernel bug:
For example, a vanilla Ubuntu 16.04.3 LTS has a kernel with this problem.
I discovered the problem by accident when trying out the latest Qt Creator snapshot, which gave error dialogs about not being able to write its configuration files.
This minimal example shows the problem:
With Qt 5.10 beta 1 on Linux 4.10.0-37-generic I get
This minimal renameat2 program also shows the kernel bug:
[estan@newton renameat2tc]$ touch foo
[estan@newton renameat2tc]$ ./renameat2 foo bar
On Linux 4.4.0, it works without error.
Since this is a kernel bug, and recent Qt just happened to be affected by it, I'm not sure what should be done if anything.
But Ubuntu 16.04 is such a common distro (and has the affected kernel) that I suspect many people will be hit by this, so maybe there's a workaround that could be made in Qt?
|For Gerrit Dashboard: QTBUG-64008|
|209385,3||QFileSystemEngine: Fix renameat2() failures on non-local filesystems||5.10||qt/qtbase||Status: MERGED||+2||0|