git.samba.org
/
samba.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
lib: Make sid_parse return the parsed length
[samba.git]
/
source3
/
lib
/
tldap_util.c
diff --git
a/source3/lib/tldap_util.c
b/source3/lib/tldap_util.c
index 3938fca901f917ca79d7793cd3b61bf77331c4ea..efc37e48e7c52f44840a6b88d78388aeff2f8995 100644
(file)
--- a/
source3/lib/tldap_util.c
+++ b/
source3/lib/tldap_util.c
@@
-88,11
+88,13
@@
bool tldap_pull_binsid(struct tldap_message *msg, const char *attribute,
struct dom_sid *sid)
{
DATA_BLOB val;
struct dom_sid *sid)
{
DATA_BLOB val;
+ struct sid_parse_ret ret;
if (!tldap_get_single_valueblob(msg, attribute, &val)) {
return false;
}
if (!tldap_get_single_valueblob(msg, attribute, &val)) {
return false;
}
- return sid_parse(val.data, val.length, sid);
+ ret = sid_parse(val.data, val.length, sid);
+ return (ret.len != -1);
}
bool tldap_pull_guid(struct tldap_message *msg, const char *attribute,
}
bool tldap_pull_guid(struct tldap_message *msg, const char *attribute,