libxl: prepare environment for domcreate_stream_done
authorOlaf Hering <olaf@aepfle.de>
Fri, 8 Mar 2019 12:24:15 +0000 (13:24 +0100)
committerWei Liu <wei.liu2@citrix.com>
Tue, 12 Mar 2019 13:02:57 +0000 (13:02 +0000)
commit9d840969ed92182707e0871a1fda185323fcdeaa
treedae1199b45cea6dfc54425c924b7f6779286ce6b
parent58b26fb0b86ebad2b1aa3e0bffb3433df1925abf
libxl: prepare environment for domcreate_stream_done

The function domcreate_bootloader_done may branch early to
domcreate_stream_done, in case some error occoured. Here srs->dcs will be
NULL, which leads to a crash.

It is unclear what the purpose of that backpointer is. Perhaps it can be
removed, and domcreate_stream_done could use CONTAINER_OF.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: Wei Liu <wei.liu2@citrix.com>
[ wei: fold in comment required by Ian ]
Signed-off-by: Wei Liu <wei.liu2@citrix.com>
tools/libxl/libxl_create.c