提交 ebad530e 编写于 作者: M Michal Privoznik

virbuffer: Set child buffer indent properly

There's this macro virBufferSetChildIndent which sets offset of
child buffer from given parent buffer. However, it is calling
virBufferAdjustIndent() which only adds adjustment instead of
calling virBufferSetIndent() which clears out any adjustment
previously set.
Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
Reviewed-by: NJán Tomko <jtomko@redhat.com>
上级 b3f75d99
......@@ -112,7 +112,7 @@ void virBufferSetIndent(virBufferPtr, int indent);
* child buffer.
*/
# define virBufferSetChildIndent(childBuf_, parentBuf_) \
virBufferAdjustIndent(childBuf_, virBufferGetIndent(parentBuf_, false) + 2)
virBufferSetIndent(childBuf_, virBufferGetIndent(parentBuf_, false) + 2)
int virBufferGetIndent(const virBuffer *buf, bool dynamic);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册