提交 6ddbabf9 编写于 作者: M Michal Privoznik

qemu_conf: Don't discard strdup OOM error

After 78d7c3c5 we are strdup()-ing path to qemu-bridge-helper.
However, the check for its return value is missing. So it is
possible we've ignored the OOM error silently.
上级 9d6e56db
......@@ -241,7 +241,8 @@ virQEMUDriverConfigPtr virQEMUDriverConfigNew(bool privileged)
}
}
#endif
cfg->bridgeHelperName = strdup("/usr/libexec/qemu-bridge-helper");
if (!(cfg->bridgeHelperName = strdup("/usr/libexec/qemu-bridge-helper")))
goto no_memory;
cfg->clearEmulatorCapabilities = true;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册