>         if (_hurd_id.aux.nuids == 0)
>           {
>             newaux = &ruid;
>             naux = 1;
>           }

In this case we don't touch _hurd_id at all, so nothing has changed yet.

>         else
>           {
>             _hurd_id.aux.uids[0] = ruid;
>             _hurd_id.valid = 0;
>           }

In this case we've clobbered _hurd_id with speculative data that doesn't
match our actual auth port.

> why is the valid field set to 0 in the case where it is actually updated
> with the correct value?  In case the call fails?  Why don't we also set
> valid to 0 in the first case, since _hurd_id is not updated in that
> case?

At the end we call __setauth to actually do something.  That clears
_hurd_id.valid when it installs the new port.  The only way we ever set
the valid flag is in _hurd_check_ids, when we have the information exactly
as the auth server reported it.


Thanks,
Roland

Reply via email to