提交 25d45480 编写于 作者: J Ján Tomko

audit: remove redundant NULL assignment

virVasprintf sets the output to NULL on failure.
上级 c1480871
......@@ -99,10 +99,8 @@ void virAuditSend(virLogSourcePtr source,
#endif
va_start(args, fmt);
if (virVasprintf(&str, fmt, args) < 0) {
if (virVasprintf(&str, fmt, args) < 0)
VIR_WARN("Out of memory while formatting audit message");
str = NULL;
}
va_end(args);
if (auditlog && str) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册