diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Support/PathV2.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Support/PathV2.cpp b/lib/Support/PathV2.cpp index cc654eea58..c0be6f4ea1 100644 --- a/lib/Support/PathV2.cpp +++ b/lib/Support/PathV2.cpp @@ -638,7 +638,8 @@ error_code unique_file(const Twine &Model, SmallVectorImpl<char> &ResultPath, if (close(FD)) return error_code(errno, system_category()); - return fs::remove(ResultPath.begin()); + StringRef P(ResultPath.begin(), ResultPath.size()); + return fs::remove(P); } error_code make_absolute(SmallVectorImpl<char> &path) { |