Add a check of the return for virDomainHostdevInsert() like every other call. Signed-off-by: John Ferlan <jferlan@xxxxxxxxxx> --- src/libxl/libxl_driver.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index 17d6257..2f2c590 100644 --- a/src/libxl/libxl_driver.c +++ b/src/libxl/libxl_driver.c @@ -2891,7 +2891,8 @@ libxlDomainAttachDeviceConfig(virDomainDefPtr vmdef, virDomainDeviceDefPtr dev) return -1; } - virDomainHostdevInsert(vmdef, hostdev); + if (virDomainHostdevInsert(vmdef, hostdev) < 0) + return -1; break; default: -- 1.9.3 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list