Skip to content

net: do not wait on EAGAIN from lossy packet conn #5932

Closed
@gopherbot

Description

@gopherbot

by [email protected]:

When writing to a connection created by net.Dial("unixgram",
"/dev/log") I will occasionally get an EAGAIN returned.  When that happens the
internal WaitWrite call will block forever if no deadline is set.  I can break by
setting a deadline.  Writing to the connection after the timeout error works so it looks
like the WaitWrite is not working properly for this type of socket.  It happens for both
the Write and the WriteToUnix calls.

I don't know how to create an EAGAIN from a unixgram type socket so I don't have a test
case.  It was very difficult to reproduce this against rsyslog.  I'm hoping a socket
expert can figure it out an easy way to reproduce this.

This bug started on go1.1 and is reproducible on go1.1.1 (never saw it on 1.0.x). 
amd64/linux (ubuntu 12.04)

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeSuggestedIssues that may be good for new contributors looking for work to do.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions