Fix bug for inet_getname