You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[core] fix crash when trying to open a Windows ISO with a very long path
* The current wimlib code makes repeated attempts to close stdin (0) on cleanup when a WIM cannot
be opened, which doesn't sit too well with MSFT's _close() as it invokes an invalid parameter
exception handler that can make the application crash...
* This may happen when we try to open the WIM from an ISO that has been truncated because it
resides on a path that is longer than MAX_PATH on account that wimlib repeatedly attempts to
close the phantom stdin fd's it sees assigned to its internal (and unused) WIMStruct after it
errors out on trying to open the image.
* So we declare stdin as invalid for use with Visual Studio compiled apps.
* For good measure we also increase the size of the string arrays we used for WIM paths to 1024
UTF-8 characters, and add explicit asserts in case we have to truncate these paths (since we
are quite curious about real-life scenarios where people need paths longer than 1024).
* Closespbatard#2777.
* Also improve the safe_strcp() and safe_sprintf() macros and fix some unwarranted "Command was
terminated by user" messages introduced in commit ea01cd4.
0 commit comments