From d77e8aefe342ab80b5d90df6a08ce5d51a59199e Mon Sep 17 00:00:00 2001 From: Ashok Thirumurthi Date: Fri, 3 May 2013 15:56:59 +0000 Subject: Fixed 'command script import' by eliminating the shadowing of basename. Reviewed by: Daniel Malea llvm-svn: 181027 --- lldb/source/Interpreter/ScriptInterpreterPython.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lldb/source/Interpreter/ScriptInterpreterPython.cpp') diff --git a/lldb/source/Interpreter/ScriptInterpreterPython.cpp b/lldb/source/Interpreter/ScriptInterpreterPython.cpp index 8d41f71d83d..3206154224b 100644 --- a/lldb/source/Interpreter/ScriptInterpreterPython.cpp +++ b/lldb/source/Interpreter/ScriptInterpreterPython.cpp @@ -2593,8 +2593,8 @@ ScriptInterpreterPython::LoadScriptingModule (const char* pathname, { FileSpec target_file(pathname, true); + std::string basename(target_file.GetFilename().GetCString()); - std::string basename; StreamString command_stream; // Before executing Pyton code, lock the GIL. @@ -2612,7 +2612,6 @@ ScriptInterpreterPython::LoadScriptingModule (const char* pathname, else { const char* directory = target_file.GetDirectory().GetCString(); - std::string basename(target_file.GetFilename().GetCString()); // now make sure that Python has "directory" in the search path StreamString command_stream; -- cgit v1.2.3