[TIPC]: Add error check to detect non-blocking form of connect()

This patch causes TIPC to return an error indication if the non-
blocking form of connect() is requested (which TIPC does not yet
support).

Signed-off-by: Allan Stephens <allan.stephens@windriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/net/tipc/socket.c b/net/tipc/socket.c
index 4c83aba..348e4ff 100644
--- a/net/tipc/socket.c
+++ b/net/tipc/socket.c
@@ -1260,6 +1260,11 @@
    if (sock->state == SS_READY)
 	   return -EOPNOTSUPP;
 
+   /* For now, TIPC does not support the non-blocking form of connect() */
+
+   if (flags & O_NONBLOCK)
+	   return -EWOULDBLOCK;
+
    /* Issue Posix-compliant error code if socket is in the wrong state */
 
    if (sock->state == SS_LISTENING)