[SCM] Samba Shared Repository - branch v3-5-test updated
Karolin Seeger
kseeger at samba.org
Thu Jul 1 04:19:01 MDT 2010
The branch, v3-5-test has been updated
via 3c4353d... s3-librpc: Fixed GUID_from_data_blob() with length of 32.
from 28f6e41... WHATSNEW: Start release notes for 3.5.5.
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-5-test
- Log -----------------------------------------------------------------
commit 3c4353d2aa15db278bb87c949cce2deb3a5072ca
Author: Andreas Schneider <asn at samba.org>
Date: Mon Jun 28 21:00:30 2010 +0200
s3-librpc: Fixed GUID_from_data_blob() with length of 32.
If we hit the case that the blob length is 32. The code goes to the end
of the function and generates a GUID with garbage.
So try to convert the blob to the GUID and return.
Fix bug #7538 (Backport fixes for GUID_from_data_blob).
-----------------------------------------------------------------------
Summary of changes:
librpc/ndr/uuid.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
Changeset truncated at 500 lines:
diff --git a/librpc/ndr/uuid.c b/librpc/ndr/uuid.c
index 2b47246..80c35cd 100644
--- a/librpc/ndr/uuid.c
+++ b/librpc/ndr/uuid.c
@@ -81,11 +81,12 @@ _PUBLIC_ NTSTATUS GUID_from_data_blob(const DATA_BLOB *s, struct GUID *guid)
} else if (s->length == 32) {
size_t rlen = strhex_to_str((char *)blob16.data, blob16.length,
(const char *)s->data, s->length);
- if (rlen == blob16.length) {
- /* goto the ndr_pull_struct_blob() path */
- status = NT_STATUS_OK;
- s = &blob16;
+ if (rlen != blob16.length) {
+ return NT_STATUS_INVALID_PARAMETER;
}
+
+ s = &blob16;
+ return GUID_from_ndr_blob(s, guid);
}
if (s->length == 16) {
--
Samba Shared Repository
More information about the samba-cvs
mailing list