From 29690449912aa85b8b5bbd9a2105b1afd082089d Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Sun, 20 Dec 2015 13:30:39 +0000 Subject: Remove call to non-existant function. There was no implementation of dom_document_get_base, and call to it were trying to run code at 0x0. Replace with call to dom_document_get_uri instead. --- src/core/document.h | 24 ------------------------ src/core/node.c | 2 +- 2 files changed, 1 insertion(+), 25 deletions(-) (limited to 'src') diff --git a/src/core/document.h b/src/core/document.h index 2837893..5cf5dc1 100644 --- a/src/core/document.h +++ b/src/core/document.h @@ -243,30 +243,6 @@ dom_exception _dom_document_set_text_content(dom_node_internal *node, _dom_node_set_user_data, \ _dom_node_get_user_data -/** \todo Unused! */ -/** - * The internal used vtable for document - */ -struct dom_document_protected_vtable { - struct dom_node_protect_vtable base; - dom_exception (*dom_document_get_base)(dom_document *doc, - dom_string **base_uri); - /* Get the document's base uri */ -}; - -typedef struct dom_document_protected_vtable dom_document_protected_vtable; - -/* Get the document's base URI */ -static inline dom_exception dom_document_get_base(dom_document *doc, - dom_string **base_uri) -{ - dom_node_internal *node = (dom_node_internal *) doc; - return ((dom_document_protected_vtable *) node->vtable)-> - dom_document_get_base(doc, base_uri); -} -#define dom_document_get_base(d, b) dom_document_get_base( \ - (dom_document *) (d), (dom_string **) (b)) - /* Following comes the protected vtable */ void _dom_document_destroy(dom_node_internal *node); dom_exception _dom_document_copy(dom_node_internal *old, diff --git a/src/core/node.c b/src/core/node.c index e0c686f..45db915 100644 --- a/src/core/node.c +++ b/src/core/node.c @@ -1370,7 +1370,7 @@ dom_exception _dom_node_get_base(dom_node_internal *node, struct dom_document *doc = node->owner; assert(doc != NULL); - return dom_document_get_base(doc, result); + return _dom_document_get_uri(doc, result); } /** -- cgit v1.2.3