[PATCH] D50126: [Support] fix TempFile infinite loop and permission denied errors

Bob Haarman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 31 19:24:05 PDT 2018


inglorion created this revision.
inglorion added reviewers: pcc, rnk, zturner.
Herald added a subscriber: hiraditya.

On Windows, TempFile::create() was prone to failing with permission
denied errors when a process created many tempfiles without providing
a model large enough to accommodate them. There was also a problem
with createUniqueEntity getting into an infinite loop when all names
permitted by the model are in use. This change fixes both of these
problems and adds a unit test for them.


https://reviews.llvm.org/D50126

Files:
  llvm/lib/Support/Path.cpp
  llvm/unittests/Support/Path.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50126.158454.patch
Type: text/x-patch
Size: 4282 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180801/addc473e/attachment.bin>


More information about the llvm-commits mailing list