unix: fix handling error on UDP socket creation