summaryrefslogtreecommitdiffstats
path: root/doc/src/snippets/code/doc_src_qtscript.js
diff options
context:
space:
mode:
authorJoão Abecasis <joao.abecasis@nokia.com>2011-03-25 17:13:04 (GMT)
committerJoão Abecasis <joao.abecasis@nokia.com>2011-04-04 11:22:48 (GMT)
commit2c3d675b97c52ad925891de16d2ea9dcfa9fae4c (patch)
tree76c2ae667f6c9cc40de38120b2f6a2e2cdec2d54 /doc/src/snippets/code/doc_src_qtscript.js
parent1c09fc7013f0058ff96c52a39637d0167d084dce (diff)
downloadQt-2c3d675b97c52ad925891de16d2ea9dcfa9fae4c.zip
Qt-2c3d675b97c52ad925891de16d2ea9dcfa9fae4c.tar.gz
Qt-2c3d675b97c52ad925891de16d2ea9dcfa9fae4c.tar.bz2
Don't pre-check if directory exists as it's unnecessary
On Posix platforms, when attempting to atomically create file and obtain descriptor, we only continue if we get an EEXIST error. If the path points to a non-existing directory, we should get ENOENT and will fail as well. On Windows, the check was already ignored. We would detect the file does not exist, attempt to obtain a handle upon return to QTemporaryFileEngine::open and fail there without running "for a *very* long time". Checking if the directory exists beforehand is not only unnecessary it also constitutes a race condition. Trusting the result of this check is dangerous and doubly useless. Reviewed-by: Olivier Goffart Reviewed-by: Robin Burchell
Diffstat (limited to 'doc/src/snippets/code/doc_src_qtscript.js')
0 files changed, 0 insertions, 0 deletions