diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-02-20 12:16:20 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:18:06 -0500 |
commit | b45442e46d595337c17829aed2d846a8c8963e6e (patch) | |
tree | e214e9ab68862234b5f9d38646f100a54c2a2b28 /source3 | |
parent | f77bdcf6c71a9d0274d96298b136300d5bb05bb1 (diff) | |
download | samba-b45442e46d595337c17829aed2d846a8c8963e6e.tar.gz samba-b45442e46d595337c17829aed2d846a8c8963e6e.tar.bz2 samba-b45442e46d595337c17829aed2d846a8c8963e6e.zip |
r21461: Not strictly necessary, as data_blob() panics if it can't allocate. But I'd
see this as a design flaw in data_blob() and it made me look in that routine.
Jeremy, revert or merge please :-)
Volker
(This used to be commit e7e6b8b5e0b00cc0746db4e9baa2e860074f903a)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/smbd/sesssetup.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c index 9b9ae4c353..6ca306ac25 100644 --- a/source3/smbd/sesssetup.c +++ b/source3/smbd/sesssetup.c @@ -828,6 +828,10 @@ static NTSTATUS check_spnego_blob_complete(uint16 smbpid, uint16 vuid, DATA_BLOB } pad->needed_len = needed_len - pblob->length; pad->partial_data = data_blob(pblob->data, pblob->length); + if (pad->partial_data.data == NULL) { + SAFE_FREE(pad); + return NT_STATUS_NO_MEMORY; + } pad->smbpid = smbpid; pad->vuid = vuid; DLIST_ADD(pd_list, pad); |