Added EINTR handler in recv function