summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Silverstone <dsilvers@digital-scurf.org>2012-11-03 23:09:39 +0000
committerDaniel Silverstone <dsilvers@digital-scurf.org>2012-11-03 23:09:39 +0000
commit15024114ed3af91058f85158803fb9c5e61b05fb (patch)
treeed86cf8e60b767fe1d9f1ec838338115fdfd5dfb
parentdb72501b96a6e87c4aa0a53bfad4aa107cbab1a1 (diff)
parent411acd732203e2aff077fff73d5e920983cfe70b (diff)
downloadlibdom-15024114ed3af91058f85158803fb9c5e61b05fb.tar.gz
libdom-15024114ed3af91058f85158803fb9c5e61b05fb.tar.bz2
Merge branch 'master' of git://git.netsurf-browser.org/libdom
-rw-r--r--src/core/document_type.c26
1 files changed, 12 insertions, 14 deletions
diff --git a/src/core/document_type.c b/src/core/document_type.c
index a01abce..d7b1b99 100644
--- a/src/core/document_type.c
+++ b/src/core/document_type.c
@@ -243,18 +243,17 @@ dom_exception _dom_document_type_get_notations(
* The returned string will have its reference count increased. It is
* the responsibility of the caller to unref the string once it has
* finished with it.
- *
- * We don't support this API now, so this function call should always
- * return DOM_NOT_SUPPORTED_ERR.
*/
dom_exception _dom_document_type_get_public_id(
dom_document_type *doc_type,
dom_string **result)
{
- UNUSED(doc_type);
- UNUSED(result);
-
- return DOM_NOT_SUPPORTED_ERR;
+ if (doc_type->public_id != NULL)
+ *result = dom_string_ref(doc_type->public_id);
+ else
+ *result = NULL;
+
+ return DOM_NO_ERR;
}
/**
@@ -267,18 +266,17 @@ dom_exception _dom_document_type_get_public_id(
* The returned string will have its reference count increased. It is
* the responsibility of the caller to unref the string once it has
* finished with it.
- *
- * We don't support this API now, so this function call should always
- * return DOM_NOT_SUPPORTED_ERR.
*/
dom_exception _dom_document_type_get_system_id(
dom_document_type *doc_type,
dom_string **result)
{
- UNUSED(doc_type);
- UNUSED(result);
-
- return DOM_NOT_SUPPORTED_ERR;
+ if (doc_type->system_id != NULL)
+ *result = dom_string_ref(doc_type->system_id);
+ else
+ *result = NULL;
+
+ return DOM_NO_ERR;
}
/**