Opened 11 years ago

Closed 11 years ago

#6048 closed Bugs (fixed)

async_connect sometimes returns succes in case of error

Reported by: Gennady Proskurin <gpr@…> Owned by: chris_kohlhoff
Milestone: To Be Determined Component: asio
Version: Boost 1.47.0 Severity: Problem
Keywords: Cc:

Description

When listen queue of unix local socket is overflowed, connect() syscall returns EAGAIN, asio does not treat this as error and returns success to async_connect handler.

Reproduced on the following system: Linux maildesk-test 2.6.32-5-amd64 #1 SMP Tue Jun 14 09:42:28 UTC 2011 x86_64 GNU/Linux.

Test program attached, it tries to do write() after successful connect.

Attachments (1)

conn.cc (1.4 KB ) - added by Gennady Proskurin <gpr@…> 11 years ago.

Download all attachments as: .zip

Change History (3)

by Gennady Proskurin <gpr@…>, 11 years ago

Attachment: conn.cc added

comment:1 by chris_kohlhoff, 11 years ago

(In [76430]) On linux, connect can return EAGAIN in certain circumstances. Remap to another error so that it doesn't look like a non-blocking operation. Refs #6048.

comment:2 by chris_kohlhoff, 11 years ago

Resolution: fixed
Status: newclosed

(In [76516]) Merge from trunk:

  • Chrono support.
  • Added object_handle support.
  • Need to enable the basic_handle class when object_handle is supported.
  • Update copyright notices.
  • Fix MSVC "performance warning".
  • Fix for NetBSD. Fixes #6098.
  • Fix regression in buffered_write_stream. Fixes #6310.
  • Fix deadlock on Mac OS X. Fixes #6275.
  • On linux, connect can return EAGAIN in certain circumstances. Remap to another error so that it doesn't look like a non-blocking operation. Fixes #6048.
  • Fix non-paged pool "leak" on Windows when io_service is repeatedly run without anything to do. Fixes #6321.
  • Disable object_handle on Windows CE.
  • Add extra include required for OVERLAPPED struct.
  • Fix doxygen comments.
  • Update documentation.
  • Add missing class.
  • Update copyright year.
Note: See TracTickets for help on using tickets.