From 7b8a85a8df1431a17c8c3c78204502b894c71fcd Mon Sep 17 00:00:00 2001 From: David Nadlinger Date: Tue, 8 Oct 2013 17:56:10 +0200 Subject: [PATCH] Fix prependMainExecutablePath for LLVM 3.4. --- driver/ldmd.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/driver/ldmd.cpp b/driver/ldmd.cpp index a6089a8e..57f2d92d 100644 --- a/driver/ldmd.cpp +++ b/driver/ldmd.cpp @@ -126,7 +126,10 @@ static std::string prependMainExecutablePath(const std::string &ExeName, if (!Result.empty()) { sys::path::append(Result, ExeName); - sys::path::append(Result, getEXESuffix()); + + // Do not use path::append here, this is not a path component before which + // to insert the path seperator. + Result.append(getEXESuffix()); } return Result.str();