From c75dc7412babbd8194e569268008df39a7644da1 Mon Sep 17 00:00:00 2001 From: Ahmed Charles Date: Wed, 5 Mar 2014 05:04:00 +0000 Subject: [PATCH] Remove unnecessary variables. Found self-hosting clang-cl on windows. :) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@202935 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Support/Windows/Process.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Support/Windows/Process.inc b/lib/Support/Windows/Process.inc index a794ca08f67..a87c9e88c71 100644 --- a/lib/Support/Windows/Process.inc +++ b/lib/Support/Windows/Process.inc @@ -154,7 +154,7 @@ void Process::PreventCoreFiles() { Optional Process::GetEnv(StringRef Name) { // Convert the argument to UTF-16 to pass it to _wgetenv(). SmallVector NameUTF16; - if (error_code ec = windows::UTF8ToUTF16(Name, NameUTF16)) + if (windows::UTF8ToUTF16(Name, NameUTF16)) return None; // Environment variable can be encoded in non-UTF8 encoding, and there's no @@ -175,7 +175,7 @@ Optional Process::GetEnv(StringRef Name) { // Convert the result from UTF-16 to UTF-8. SmallVector Res; - if (error_code ec = windows::UTF16ToUTF8(Buf.data(), Size, Res)) + if (windows::UTF16ToUTF8(Buf.data(), Size, Res)) return None; return std::string(Res.data()); } -- 2.34.1