summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2009-12-10 14:48:56 +1100
committerAndrew Tridgell <tridge@samba.org>2009-12-10 17:51:30 +1100
commit62dc7f6b2dd7df83740e4761988eb2f87205c73c (patch)
tree6f5f9e1d8548aeb72e18c57ba0e60f6986f86833 /source4
parentc7c97b61aef94d6adc786b3e6eb6e347d1d9382c (diff)
downloadsamba-62dc7f6b2dd7df83740e4761988eb2f87205c73c.tar.gz
samba-62dc7f6b2dd7df83740e4761988eb2f87205c73c.tar.bz2
samba-62dc7f6b2dd7df83740e4761988eb2f87205c73c.zip
s4-libcli: GUID_from_ndr_blob() is strict about the blob size
We need to create a blob of the right length
Diffstat (limited to 'source4')
-rw-r--r--source4/libcli/raw/rawfsinfo.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source4/libcli/raw/rawfsinfo.c b/source4/libcli/raw/rawfsinfo.c
index 4c79ba066c..15599adebe 100644
--- a/source4/libcli/raw/rawfsinfo.c
+++ b/source4/libcli/raw/rawfsinfo.c
@@ -214,14 +214,16 @@ NTSTATUS smb_raw_fsinfo_passthru_parse(DATA_BLOB blob, TALLOC_CTX *mem_ctx,
fsinfo->full_size_information.out.bytes_per_sector = IVAL(blob.data, 28);
break;
- case RAW_QFS_OBJECTID_INFORMATION:
+ case RAW_QFS_OBJECTID_INFORMATION: {
+ DATA_BLOB b2 = data_blob_const(blob.data, MIN(16, blob.length));
QFS_CHECK_SIZE(64);
- status = GUID_from_ndr_blob(&blob, &fsinfo->objectid_information.out.guid);
+ status = GUID_from_ndr_blob(&b2, &fsinfo->objectid_information.out.guid);
NT_STATUS_NOT_OK_RETURN(status);
for (i=0;i<6;i++) {
fsinfo->objectid_information.out.unknown[i] = BVAL(blob.data, 16 + i*8);
}
break;
+ }
default:
status = NT_STATUS_INVALID_INFO_CLASS;