CYGWIN: Fix port auto connection. (#211)

This commit is contained in:
HiFiPhile 2023-09-22 11:53:37 +02:00 committed by GitHub
parent 1777206de7
commit 72399c4fe6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1576,6 +1576,13 @@ int tty_connect(void)
}
else if (status == -1)
{
#if defined(__CYGWIN__)
// Happens when port unpluged
if (errno == EACCES)
{
goto error_read;
}
#endif
tio_error_printf("select() failed (%s)", strerror(errno));
exit(EXIT_FAILURE);
}