Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests: fix error handling around UNIX sockets #11265

Closed
wants to merge 3 commits into from

Conversation

dfandrich
Copy link
Contributor

The wrong error code was checked on Windows, which may have caused all
UNIX sockets to be reported as error and the tests skipped.

Fixes #11258
Closes #11265

@github-actions github-actions bot added the tests label Jun 7, 2023
@dfandrich
Copy link
Contributor Author

@gvanem Would you mind taking a look?

@dfandrich dfandrich added the Windows Windows-specific label Jun 7, 2023
dfandrich added a commit that referenced this pull request Jun 7, 2023
The wrong error code was checked on Windows, which may have caused all
UNIX sockets to be reported as error and the tests skipped.

Fixes #11258
Closes #11265
@gvanem
Copy link
Contributor

gvanem commented Jun 7, 2023

@dfandrich No change. Same Error binding socket: (10045) Unknown error.
Some deeply hidden issue in afunix.sys?

@dfandrich
Copy link
Contributor Author

dfandrich commented Jun 7, 2023 via email

dfandrich added a commit that referenced this pull request Jun 7, 2023
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Fixes #11258
Closes #11265
dfandrich added a commit that referenced this pull request Jun 7, 2023
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Ref #11258
Closes #11265
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Ref #11258
Closes #11265
dfandrich added a commit that referenced this pull request Jun 9, 2023
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Ref #11258
Closes #11265
@@ -2779,6 +2779,7 @@ sub displaylogs {
# a new one shortly. If all runners are busy, wait indefinitely for one to
# finish.
my $runnerwait = scalar(@runnersidle) && scalar(@runtests) ? 0 : undef;
print STDERR "TESTING waiting indefinitely for test completion\n" if(!scalar(@runtests));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this print a debugging leftover or meant to actually be a plain STDERR output? It looks like an anomaly in the code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just a debugging leftover. It won't be submitted.

@dfandrich dfandrich closed this in b65086a Jun 10, 2023
@dfandrich dfandrich deleted the dfandrich/testerrno branch June 10, 2023 15:30
bch pushed a commit to bch/curl that referenced this pull request Jul 19, 2023
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Ref curl#11258
Closes curl#11265
ptitSeb pushed a commit to wasix-org/curl that referenced this pull request Sep 25, 2023
The wrong error code was checked on Windows on UNIX socket failures,
which could have caused all UNIX sockets to be reported as having
errored and the tests therefore skipped. Also, a useless error message
was displayed on socket errors in many test servers on Windows because
strerror() doesn't work on WinSock error codes; perror() is overridden
there to work on all errors and is used instead.

Ref curl#11258
Closes curl#11265
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests Windows Windows-specific
Development

Successfully merging this pull request may close these issues.

Native Windows can't create UNIX sockets
3 participants