subproc: sub_proc: Added pointer judgment after allocation

Signed-off-by: Li kunyu <kunyu@nfschina.com>
This commit is contained in:
Li kunyu 2022-11-18 13:12:40 +08:00
parent 5690084634
commit 392f405f60

View File

@ -394,6 +394,9 @@ process_init()
BYTE sd[SECURITY_DESCRIPTOR_MIN_LENGTH];
pproc = malloc(sizeof(*pproc));
if (!pproc)
return((HANDLE)NULL);
memset(pproc, 0, sizeof(*pproc));
/* We can't use NULL for lpSecurityDescriptor because that