提交 323f7c47 编写于 作者: M Martin Kletzander

util: Use virBufferCheckError to its full potential.

We can now check for the error and not care about the return value as
it will be properly handled in virBufferContentAndReset() anyway.
Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
上级 7addfa19
...@@ -332,11 +332,7 @@ char *virBitmapString(virBitmapPtr bitmap) ...@@ -332,11 +332,7 @@ char *virBitmapString(virBitmapPtr bitmap)
bitmap->map[sz]); bitmap->map[sz]);
} }
if (virBufferError(&buf)) { virBufferCheckError(&buf);
virBufferFreeAndReset(&buf);
return NULL;
}
return virBufferContentAndReset(&buf); return virBufferContentAndReset(&buf);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册