[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-27 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman closed 
https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-27 Thread Pavel Labath via lldb-commits

https://github.com/labath edited https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-27 Thread Pavel Labath via lldb-commits


@@ -678,8 +678,8 @@ uint32_t PlatformPOSIX::DoLoadImage(lldb_private::Process 
*process,
 loaded_image->Clear();
 
   std::string path;

labath wrote:

```suggestion
  std::string path = remote_file.GetPath(false);
```
Might as well fold the assignment into the declaration.

https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-27 Thread Pavel Labath via lldb-commits

https://github.com/labath approved this pull request.

> BTW, it would be great to be able to pass the style or triple to SBFileSpec. 
> Currently it is impossible to create a posix SBFileSpec on the Windows host.

This is definitely not intentional. Feel free to create a PR to add it.

https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-24 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman edited 
https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-24 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman updated 
https://github.com/llvm/llvm-project/pull/93345

>From 8701bfc715168168ca04d86f134ef362d5e89173 Mon Sep 17 00:00:00 2001
From: Dmitry Vasilyev 
Date: Sat, 25 May 2024 00:39:05 +0400
Subject: [PATCH] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the
 Windows host

Do not denormalize the path. This patch fixes #93092.

BTW, it would be great to be able to pass the style or triple to SBFileSpec. 
Currently it is impossible to create a posix FileSpec on the Windows host.
---
 lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp 
b/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
index b4f1b76c39dbe..588b19dac6165 100644
--- a/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
+++ b/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
@@ -678,8 +678,8 @@ uint32_t PlatformPOSIX::DoLoadImage(lldb_private::Process 
*process,
 loaded_image->Clear();
 
   std::string path;
-  path = remote_file.GetPath();
-  
+  path = remote_file.GetPath(false);
+
   ThreadSP thread_sp = process->GetThreadList().GetExpressionExecutionThread();
   if (!thread_sp) {
 error.SetErrorString("dlopen error: no thread available to call dlopen.");

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-24 Thread via lldb-commits

github-actions[bot] wrote:




:warning: C/C++ code formatter, clang-format found issues in your code. 
:warning:



You can test this locally with the following command:


``bash
git-clang-format --diff b91b8fea8c58e9b414e291df677b12ca44197784 
76a35a6ca5302aef5033d5ae297667e416921d7d -- 
lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
``





View the diff from clang-format here.


``diff
diff --git a/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp 
b/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
index edad606e2e..588b19dac6 100644
--- a/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
+++ b/lldb/source/Plugins/Platform/POSIX/PlatformPOSIX.cpp
@@ -679,7 +679,7 @@ uint32_t PlatformPOSIX::DoLoadImage(lldb_private::Process 
*process,
 
   std::string path;
   path = remote_file.GetPath(false);
-  
+
   ThreadSP thread_sp = process->GetThreadList().GetExpressionExecutionThread();
   if (!thread_sp) {
 error.SetErrorString("dlopen error: no thread available to call dlopen.");

``




https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-24 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman edited 
https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] [lldb] Fixed PlatformPOSIX::DoLoadImage() in case of the Windows host (PR #93345)

2024-05-24 Thread Dmitry Vasilyev via lldb-commits

https://github.com/slydiman edited 
https://github.com/llvm/llvm-project/pull/93345
___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits