Convert C14N to the new Input buffer
one case of direct access cleaned up
diff --git a/c14n.c b/c14n.c
index 9c3cad2..5d891c9 100644
--- a/c14n.c
+++ b/c14n.c
@@ -27,6 +27,8 @@
#include <libxml/xpathInternals.h>
#include <libxml/c14n.h>
+#include "buf.h"
+
/************************************************************************
* *
* Some declaration better left private ATM *
@@ -2033,9 +2035,9 @@
return (-1);
}
- ret = buf->buffer->use;
+ ret = xmlBufUse(buf->buffer);
if (ret > 0) {
- *doc_txt_ptr = xmlStrndup(buf->buffer->content, ret);
+ *doc_txt_ptr = xmlStrndup(xmlBufContent(buf->buffer), ret);
}
(void) xmlOutputBufferClose(buf);