Skip to content

Commit

Permalink
s3:idmap_cache: also store negative entries for unknown sids
Browse files Browse the repository at this point in the history
metze

Autobuild-User(master): Stefan Metzmacher <[email protected]>
Autobuild-Date(master): Thu Jun 21 18:04:05 CEST 2012 on sn-devel-104
  • Loading branch information
metze-samba committed Jun 21, 2012
1 parent a65173a commit 3c74117
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions source3/lib/idmap_cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,10 @@ bool idmap_cache_find_sid2unixid(const struct dom_sid *sid, struct unixid *id,
tmp_id.type = ID_TYPE_BOTH;
break;

case 'N':
tmp_id.type = ID_TYPE_NOT_SPECIFIED;
break;

case '\0':
DEBUG(0, ("FAILED to parse value for key [%s] "
"(id=[%llu], endptr=[%s]): "
Expand Down Expand Up @@ -289,6 +293,9 @@ void idmap_cache_set_sid2unixid(const struct dom_sid *sid, struct unixid *unix_i
case ID_TYPE_BOTH:
fstr_sprintf(value, "%d:B", (int)unix_id->id);
break;
case ID_TYPE_NOT_SPECIFIED:
fstr_sprintf(value, "%d:N", (int)unix_id->id);
break;
default:
return;
}
Expand Down

0 comments on commit 3c74117

Please sign in to comment.