The socket is associated with a connection-oriented protocol and has not been connected. This is usually a programming flaw. See connect(2) for more details.
5 pages link to ENOTCONN: