[Lldb-commits] [PATCH] linux: Add missing FileSpec argument.

Stephen Wilson wilsons at start.ca
Mon Dec 20 12:25:16 PST 2010


Provide a missing resolve_path argument in calls to FileSpec's
constructor for both Linux and FreeBSD code fragments.


diff --git a/source/Host/common/Host.cpp b/source/Host/common/Host.cpp
index 527d20a..28a6d00 100644
--- a/source/Host/common/Host.cpp
+++ b/source/Host/common/Host.cpp
@@ -622,7 +622,7 @@ Host::GetProgramFileSpec ()
         char exe_path[PATH_MAX];
         ssize_t len = readlink("/proc/self/exe", exe_path, sizeof(exe_path));
         if (len >= 0)
-            g_program_filespec = FileSpec(exe_path);
+            g_program_filespec = FileSpec(exe_path, true);
 #elif defined (__FreeBSD__)
         int exe_path_mib[4] = { CTL_KERN, KERN_PROC, KERN_PROC_PATHNAME, getpid() };
         size_t exe_path_size;
@@ -630,7 +630,7 @@ Host::GetProgramFileSpec ()
         {
           char *exe_path = new char[exe_path_size];
           if (sysctl(exe_path_mib, 4, exe_path, &exe_path_size, NULL, 0) == 0)
-              g_program_filespec = FileSpec(exe_path);
+              g_program_filespec = FileSpec(exe_path, true);
         }
 #endif
     }



More information about the lldb-commits mailing list