mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-23 02:25:11 +00:00
[utils] Catch strange Windows errors (Closes #4733)
This commit is contained in:
parent
649f7966f7
commit
aa42e87340
1 changed files with 3 additions and 0 deletions
|
@ -863,6 +863,9 @@ def _windows_write_string(s, out):
|
|||
except AttributeError:
|
||||
# If the output stream doesn't have a fileno, it's virtual
|
||||
return False
|
||||
except io.UnsupportedOperation:
|
||||
# Some strange Windows pseudo files?
|
||||
return False
|
||||
if fileno not in WIN_OUTPUT_IDS:
|
||||
return False
|
||||
|
||||
|
|
Loading…
Reference in a new issue