{
uint32_t hash;
- if (sid->num_auths != 4)
- return 0;
+ if (sid->num_auths != 4) {
+ return UINT32_MAX;
+ }
/* XOR the last three subauths */
continue;
}
- if ((hash = hash_domain_sid(&dom_list[i].sid)) == 0)
+ hash = hash_domain_sid(&dom_list[i].sid);
+ if (hash == UINT32_MAX) {
continue;
+ }
DBG_INFO("Adding %s (%s) -> %d\n",
dom_list[i].domain_name,
h_domain = hash_domain_sid(&sid);
h_rid = hash_rid(rid);
- /* Check that both hashes are non-zero*/
- if (h_domain == 0) {
+ /* Check that both hashes are valid */
+ if (h_domain == UINT32_MAX) {
return NT_STATUS_NONE_MAPPED;
}
if (h_rid == 0) {