]> Zhao Yanbai Git Server - minix.git/commitdiff
Fixed bug in canceling TCP ioctls before INET got an IP address.
authorPhilip Homburg <philip@cs.vu.nl>
Mon, 20 Feb 2006 14:35:01 +0000 (14:35 +0000)
committerPhilip Homburg <philip@cs.vu.nl>
Mon, 20 Feb 2006 14:35:01 +0000 (14:35 +0000)
servers/inet/generic/tcp.c

index 04b888ece8e3358786c69787fe97312469fb2d84..20f8db01d4522d604de75ee3cb0bf9d1e5106c4e 100644 (file)
@@ -1308,6 +1308,7 @@ int reply;
 int for_ioctl;
 {
        acc_t *result;
+
        result= (*tcp_fd->tf_get_userdata)(tcp_fd->tf_srfd, reply,
                (size_t)0, for_ioctl);
        assert (!result);
@@ -2027,6 +2028,13 @@ int which_operation;
 assert (tcp_fd->tf_flags & TFF_IOCTL_IP);
                tcp_fd->tf_flags &= ~TFF_IOCTL_IP;
 
+               if (tcp_fd->tf_flags & TFF_IOC_INIT_SP)
+               {
+                       tcp_fd->tf_flags &= ~TFF_IOC_INIT_SP;
+                       reply_thr_put (tcp_fd, EINTR, TRUE);
+                       break;
+               }
+
                switch (tcp_fd->tf_ioreq)
                {
                case NWIOGTCPCONF: