On Apr 26, 2013, at 6:16 PM, Jordan Rose <[email protected]> wrote:

> Actually, this should probably get off PathV1.h altogether, and just use 
> llvm::sys::fs::current_path in FileSystem.h.
> 
> Sorry for asking you to change this again…

No worries, thanks for the suggestion.  I put in a temporary fix to appease the 
bots and gdb tests.  I'll give your suggestion a try once I am able to continue 
watching the bots.  For now I need to get out of the office.

Thanks, Jordan.

> 
> On Apr 26, 2013, at 17:57 , Chad Rosier <[email protected]> wrote:
> 
>> Author: mcrosier
>> Date: Fri Apr 26 19:57:18 2013
>> New Revision: 180658
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=180658&view=rev
>> Log:
>> Fix the dangling pointer.
>> 
>> Modified:
>>    cfe/trunk/lib/Driver/Tools.cpp
>> 
>> Modified: cfe/trunk/lib/Driver/Tools.cpp
>> URL: 
>> http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=180658&r1=180657&r2=180658&view=diff
>> ==============================================================================
>> --- cfe/trunk/lib/Driver/Tools.cpp (original)
>> +++ cfe/trunk/lib/Driver/Tools.cpp Fri Apr 26 19:57:18 2013
>> @@ -1792,8 +1792,8 @@ static void addDebugCompDirArg(const Arg
>>     return;
>>   }
>>   // Fall back to using getcwd.
>> -  const char *cwd = llvm::sys::Path::GetCurrentDirectory().c_str();
>> -  if (pwd && cwd) {
>> +  std::string cwd = llvm::sys::Path::GetCurrentDirectory().str();
>> +  if (pwd && !cwd.empty()) {
>>     CmdArgs.push_back("-fdebug-compilation-dir");
>>     CmdArgs.push_back(Args.MakeArgString(cwd));
>>   }
>> 
>> 
>> _______________________________________________
>> cfe-commits mailing list
>> [email protected]
>> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to