summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2015-12-20 13:30:39 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2015-12-20 13:32:34 +0000
commit29690449912aa85b8b5bbd9a2105b1afd082089d (patch)
tree3c9e72caaf00ab933ea5195f3d41f8eb64229acb /src/core
parent7442297ac8c3ca65c3dbb5c990e5fd4a23f8c4ec (diff)
downloadlibdom-29690449912aa85b8b5bbd9a2105b1afd082089d.tar.gz
libdom-29690449912aa85b8b5bbd9a2105b1afd082089d.tar.bz2
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.
Diffstat (limited to 'src/core')
-rw-r--r--src/core/document.h24
-rw-r--r--src/core/node.c2
2 files changed, 1 insertions, 25 deletions
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);
}
/**