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

IO::Handle::blocking does not work under windows 7 64bit [rt.cpan.org #61074] #17455

Closed
toddr opened this issue Apr 19, 2018 · 1 comment · Fixed by #21582
Closed

IO::Handle::blocking does not work under windows 7 64bit [rt.cpan.org #61074] #17455

toddr opened this issue Apr 19, 2018 · 1 comment · Fixed by #21582
Assignees
Labels
Bug dist-IO issues in the dual-life blead-first IO distribution distro-mswin32

Comments

@toddr
Copy link
Member

toddr commented Apr 19, 2018

Migrated from rt.cpan.org#61074 (status was 'new')

Requestors:

Attachments:

From deathwolf+bitcard@gmail.com on 2010-09-05 02:12:17:

IO::Handle::blocking seems to break the socket entity under windows 7
64bit(possible other OS'es).

Attached is an example of breaking code: please adjust the port and
address to something that is open on your side, and then try
uncommenting either of the IO::Handle::blocking calls. The connect will
fail with "unknown error" or "A non-blocking socket operation could not
be completed immediately." depending on the perl distribution.

Please note that $sock->blocking(0) or $sock->blocking(1) will also fail
the same way.

Issue present in both activeperl 5.10.1 and strawberry perl 5.12.1.

From deathwolf+bitcard@gmail.com on 2010-09-05 11:39:54:

Additional bug reference for a similar bug that might be related #17448

@toddr toddr transferred this issue from Dual-Life/IO Jan 20, 2020
@toddr toddr added Needs Triage dist-IO issues in the dual-life blead-first IO distribution labels Jan 20, 2020
tonycoz added a commit to tonycoz/perl5 that referenced this issue May 5, 2020
The refactor in 375ed12 meant that fd was initialized to -1,
rather than PerlIO_fileno(f) on Win32.

fixes Perl#17455
@tonycoz
Copy link
Contributor

tonycoz commented May 5, 2020

This was originally fixed in 375ed12 but then broken again in 375ed12, and the branch (which is in CI on my tonycoz/perl5 fork) fixes that.

The original report is a little confusing in that if you switch blocking off for a socket the connect() should fail with "A non-blocking socket operation could not be completed immediately."

@tonycoz tonycoz self-assigned this Jun 17, 2020
tonycoz added a commit to tonycoz/perl5 that referenced this issue Oct 23, 2023
The refactor in 375ed12 meant that fd was initialized to -1,
rather than PerlIO_fileno(f) on Win32.

fixes Perl#17455
tonycoz added a commit to tonycoz/perl5 that referenced this issue Oct 25, 2023
The refactor in 375ed12 meant that fd was initialized to -1,
rather than PerlIO_fileno(f) on Win32.

fixes Perl#17455
tonycoz added a commit that referenced this issue Oct 25, 2023
The refactor in 375ed12 meant that fd was initialized to -1,
rather than PerlIO_fileno(f) on Win32.

fixes #17455
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug dist-IO issues in the dual-life blead-first IO distribution distro-mswin32
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants