Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#601 closed defect (fixed)

Bug with TCP server socket in IOCP ioqueue and active socket causes the ioqueue to stop accepting incoming TCP connections or 100% CPU usage

Reported by: bennylp Owned by: bennylp
Priority: major Milestone: release-1.0-rc1
Component: pjlib Version: trunk
Keywords: Cc:
Backport to 1.x milestone: Backported:

Description (last modified by bennylp)

Symptom:

  1. When asynchronous accept() is called from inside on_accept_complete(), the !IOCompletionPort ioqueue will no longer be able to report incoming TCP connections.
  2. When TCP connection receives ECONNRESET, the active socket goes into tight loop that causes 100% CPU usage. This happens with select() ioqueue
  3. Premature TCP connection closure: immediate data in recv() will cause the active socket to incorrectly thinks that the connection has been closed

Change History (3)

comment:1 Changed 16 years ago by bennylp

  • Resolution set to fixed
  • Status changed from new to closed
  • Summary changed from Bug in IoCompletionPort ioqueue with TCP server socket to Bug in IoCompletionPort ioqueue with TCP server socket causes the ioqueue to stop accepting incoming TCP connections

Fixed in r2240

comment:2 Changed 16 years ago by bennylp

  • Description modified (diff)
  • Summary changed from Bug in IoCompletionPort ioqueue with TCP server socket causes the ioqueue to stop accepting incoming TCP connections to Bug with TCP server socket in IOCP ioqueue and active socket causes the ioqueue to stop accepting incoming TCP connections or 100% CPU usage

In r2246:

  • Fixed the 100% CPU usage when TCP active socket receives ECONNRESET

comment:3 Changed 16 years ago by bennylp

  • Description modified (diff)

In r2248:

  • immediate data in recv() will cause the active socket to incorrectly thinks that the connection has been closed
Note: See TracTickets for help on using tickets.