提交 8f95d5d8 编写于 作者: P Peter Krempa

qemumonitortestutils: Don't skip va_end() on error path

When allocation of memory failed the error path didn't call va_end()
causing a coverity failure.

Reported by John Ferlan.
上级 ae9ef97b
......@@ -669,7 +669,7 @@ qemuMonitorTestAddItemParams(qemuMonitorTestPtr test,
va_start(args, response);
if (VIR_ALLOC(data) < 0)
return -1;
goto error;
if (VIR_STRDUP(data->command_name, cmdname) < 0 ||
VIR_STRDUP(data->response, response) < 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册