Revision fc13fa00

b/net/socket.c
674 674
        closesocket(fd);
675 675
        return -1;
676 676
    }
677
    qemu_set_nonblock(fd);
677 678

  
678 679
    s = net_socket_fd_init(peer, model, name, fd, 0);
679 680
    if (!s) {
......
712 713
        int fd;
713 714

  
714 715
        fd = monitor_handle_fd_param(cur_mon, sock->fd);
715
        if (fd == -1 || !net_socket_fd_init(peer, "socket", name, fd, 1)) {
716
        if (fd == -1) {
717
            return -1;
718
        }
719
        qemu_set_nonblock(fd);
720
        if (!net_socket_fd_init(peer, "socket", name, fd, 1)) {
716 721
            return -1;
717 722
        }
718 723
        return 0;

Also available in: Unified diff