Fix bug in DefaultNetSocket which could let to not closing socket