]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/kern/uipc_syscalls.c
xnu-124.13.tar.gz
[apple/xnu.git] / bsd / kern / uipc_syscalls.c
index f27ada4639c87b8130ad56eed8e579db6316e2ed..d6482c0a26eb0b86c977f3121c72635833f1e336 100644 (file)
@@ -283,7 +283,7 @@ accept1(p, uap, retval, compat)
                splx(s);
                return (EWOULDBLOCK);
        }
-       while (head->so_comp.tqh_first == NULL && head->so_error == 0) {
+        while (TAILQ_EMPTY(&head->so_comp) && head->so_error == 0) {
                if (head->so_state & SS_CANTRCVMORE) {
                        head->so_error = ECONNABORTED;
                        break;
@@ -310,7 +310,7 @@ accept1(p, uap, retval, compat)
         * block allowing another process to accept the connection
         * instead.
         */
-       so = head->so_comp.tqh_first;
+       so = TAILQ_FIRST(&head->so_comp);
        TAILQ_REMOVE(&head->so_comp, so, so_list);
        head->so_qlen--;