qemu: Move the shared disk adding and sgio setting prior to attaching
The disk def could be free'ed by qemuDomainChangeEjectableMedia, which can thus cause crash if we reference the disk pointer. On the other hand, we have to remove the added shared disk entry from the table on error codepath.
Showing
想要评论请 注册 或 登录