<div style="color: rgb(0, 0, 0);">From 9dba52cd4c776cd13fb4995885f2d5b3221e819c Mon Sep 17 00:00:00 2001<br />
From: Mr-Z-2697 <74594146+Mr-Z-2697@users.noreply.github.com><br />
Date: Sun, 11 May 2025 11:30:26 +0800<br />
Subject: [PATCH] osdep.h: detect Windows named pipe by name<br />
<br />
Named pipe in Windows is more delicate, if we proceed to the steps further down, the pipe will probably be broken.<br />
---<br />
common/osdep.h | 2 ++<br />
1 file changed, 2 insertions(+)<br />
<br />
diff --git a/common/osdep.h b/common/osdep.h<br />
index 23739b7a..4f2bd0ca 100644<br />
--- a/common/osdep.h<br />
+++ b/common/osdep.h<br />
@@ -242,6 +242,8 @@ static inline int x264_vfprintf( FILE *stream, const char *format, va_list arg )<br />
static inline int x264_is_regular_file_path( const char *path )<br />
{<br />
int ret = -1;<br />
+ if ( !strncasecmp( path, "\\\\.\\pipe\\", 9 ) )<br />
+ return 0;<br />
wchar_t path_buf[MAX_PATH];<br />
wchar_t *path_utf16 = x264_utf8_to_utf16_try_buf( path, path_buf, MAX_PATH );<br />
if( path_utf16 )<br />
-- <br />
2.49.0.windows.1<br />
</div><div><br /></div><article></article>