mirror of
https://github.com/samba-team/samba.git
synced 2025-03-03 12:58:35 +03:00
libcli: Add a NULL check in dom_sid_string
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Jun 10 21:46:15 CEST 2014 on sn-devel-104
This commit is contained in:
parent
7c2b5e77b0
commit
f4e358bc8b
@ -414,6 +414,9 @@ char *dom_sid_string(TALLOC_CTX *mem_ctx, const struct dom_sid *sid)
|
|||||||
* the length
|
* the length
|
||||||
*/
|
*/
|
||||||
result = (char *)talloc_memdup(mem_ctx, buf, len+1);
|
result = (char *)talloc_memdup(mem_ctx, buf, len+1);
|
||||||
|
if (result == NULL) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* beautify the talloc_report output
|
* beautify the talloc_report output
|
||||||
|
Loading…
x
Reference in New Issue
Block a user