git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
effff54
)
s4-dsdb: use GUID_from_ndr_blob() to create dsdb_get_extended_dn_guid()
author
Andrew Tridgell
<tridge@samba.org>
Thu, 10 Dec 2009 00:23:20 +0000
(11:23 +1100)
committer
Andrew Tridgell
<tridge@samba.org>
Thu, 10 Dec 2009 06:51:26 +0000
(17:51 +1100)
source4/dsdb/common/util.c
patch
|
blob
|
history
diff --git
a/source4/dsdb/common/util.c
b/source4/dsdb/common/util.c
index 512230f63c0ec84eecea8e355596e2913ac6960a..dceff3643e36a96ba9b5587018f40f346d17464a 100644
(file)
--- a/
source4/dsdb/common/util.c
+++ b/
source4/dsdb/common/util.c
@@
-2721,3
+2721,17
@@
int dsdb_functional_level(struct ldb_context *ldb)
return *domainFunctionality;
}
+/*
+ return a GUID from a extended DN structure
+ */
+NTSTATUS dsdb_get_extended_dn_guid(struct ldb_dn *dn, struct GUID *guid)
+{
+ const struct ldb_val *v;
+
+ v = ldb_dn_get_extended_component(dn, "GUID");
+ if (v == NULL) {
+ return NT_STATUS_OBJECT_NAME_NOT_FOUND;
+ }
+
+ return GUID_from_ndr_blob(v, guid);
+}