This revision was automatically updated to reflect the committed changes. Closed by commit rL254117: Driver: protect from empty -L args (authored by martell).
Changed prior to commit: http://reviews.llvm.org/D12466?vs=33510&id=41202#toc Repository: rL LLVM http://reviews.llvm.org/D12466 Files: cfe/trunk/lib/Driver/ToolChain.cpp Index: cfe/trunk/lib/Driver/ToolChain.cpp =================================================================== --- cfe/trunk/lib/Driver/ToolChain.cpp +++ cfe/trunk/lib/Driver/ToolChain.cpp @@ -619,7 +619,8 @@ void ToolChain::AddFilePathLibArgs(const ArgList &Args, ArgStringList &CmdArgs) const { for (const auto &LibPath : getFilePaths()) - CmdArgs.push_back(Args.MakeArgString(StringRef("-L") + LibPath)); + if(LibPath.length() > 0) + CmdArgs.push_back(Args.MakeArgString(StringRef("-L") + LibPath)); } void ToolChain::AddCCKextLibArgs(const ArgList &Args,
Index: cfe/trunk/lib/Driver/ToolChain.cpp =================================================================== --- cfe/trunk/lib/Driver/ToolChain.cpp +++ cfe/trunk/lib/Driver/ToolChain.cpp @@ -619,7 +619,8 @@ void ToolChain::AddFilePathLibArgs(const ArgList &Args, ArgStringList &CmdArgs) const { for (const auto &LibPath : getFilePaths()) - CmdArgs.push_back(Args.MakeArgString(StringRef("-L") + LibPath)); + if(LibPath.length() > 0) + CmdArgs.push_back(Args.MakeArgString(StringRef("-L") + LibPath)); } void ToolChain::AddCCKextLibArgs(const ArgList &Args,
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits