Changes
Use `NUL` instead of `/dev/null` in case of the Windows host.
---
Full diff: https://github.com/llvm/llvm-project/pull/92273.diff
1 Files Affected:
- (modified) lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py (+4-1)
``````````diff
diff --git a/lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py b/lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py
index e4f5cd3a03f86..e292885ec390d 100644
--- a/lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py
+++ b/lldb/test/API/functionalities/avoids-fd-leak/TestFdLeak.py
@@ -26,7 +26,10 @@ def test_fd_leak_basic(self):
@skipIfTargetAndroid() # Android have some other file descriptors open by the shell
@skipIfDarwinEmbedded # # debugserver on ios has an extra fd open on launch
def test_fd_leak_log(self):
- self.do_test(["log enable -f '/dev/null' lldb commands"])
+ if lldbplatformutil.getHostPlatform() == "windows":
+ self.do_test(["log enable -f 'NUL' lldb commands"])
+ else:
+ self.do_test(["log enable -f '/dev/null' lldb commands"])
def do_test(self, commands):
self.build()
``````````
Use
NUL
instead of/dev/null
in case of the Windows host.