[Lldb-commits] [lldb] Fix PATH_MAX for Windows (PR #104493)

via lldb-commits lldb-commits at lists.llvm.org
Thu Aug 15 13:04:21 PDT 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-lldb

Author: None (royitaqi)

<details>
<summary>Changes</summary>

Fix build break for Windows, caused by a [previous patch](https://github.com/llvm/llvm-project/pull/102223) using `PATH_MAX` which is undefined in Windows.

The fix is to `#include "lldb/Host/PosixApi.h"` in the source file.

---
Full diff: https://github.com/llvm/llvm-project/pull/104493.diff


1 Files Affected:

- (modified) lldb/source/Utility/RealpathPrefixes.cpp (+1) 


``````````diff
diff --git a/lldb/source/Utility/RealpathPrefixes.cpp b/lldb/source/Utility/RealpathPrefixes.cpp
index 14c81ee6a1f571..ee1c404c899676 100644
--- a/lldb/source/Utility/RealpathPrefixes.cpp
+++ b/lldb/source/Utility/RealpathPrefixes.cpp
@@ -8,6 +8,7 @@
 
 #include "lldb/Utility/RealpathPrefixes.h"
 
+#include "lldb/Host/PosixApi.h"
 #include "lldb/Utility/FileSpec.h"
 #include "lldb/Utility/FileSpecList.h"
 #include "lldb/Utility/LLDBLog.h"

``````````

</details>


https://github.com/llvm/llvm-project/pull/104493


More information about the lldb-commits mailing list