From 2b87c816994f68f9cc4ae22bcd31b6b3a203623a Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Sat, 24 Mar 2012 20:09:59 +0000 Subject: Store 'class' string as dom_string instead of lwc_string. svn path=/trunk/libdom/; revision=13616 --- src/core/document.c | 10 +++++----- src/core/document.h | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/core/document.c b/src/core/document.c index c4e0283..fbdaa7a 100644 --- a/src/core/document.c +++ b/src/core/document.c @@ -132,10 +132,10 @@ dom_exception _dom_document_initialise(dom_document *doc, doc->id_name = NULL; - if (lwc_intern_string("class", SLEN("class"), - &doc->class_string) != lwc_error_ok) { - return DOM_NO_MEM_ERR; - } + err = dom_string_create_interned((const uint8_t *) "class", + SLEN("class"), &doc->class_string); + if (err != DOM_NO_ERR) + return err; /* We should not pass a NULL when all things hook up */ return _dom_document_event_internal_initialise(doc, &doc->dei, daf); @@ -170,7 +170,7 @@ bool _dom_document_finalise(dom_document *doc) if (doc->id_name != NULL) dom_string_unref(doc->id_name); - lwc_string_unref(doc->class_string); + dom_string_unref(doc->class_string); _dom_document_event_internal_finalise(doc, &doc->dei); diff --git a/src/core/document.h b/src/core/document.h index f79c9a9..a53c358 100644 --- a/src/core/document.h +++ b/src/core/document.h @@ -52,7 +52,7 @@ struct dom_document { dom_string *id_name; /**< The ID attribute's name */ - lwc_string *class_string; /**< The string "class". */ + dom_string *class_string; /**< The string "class". */ dom_document_event_internal dei; /**< The DocumentEVent interface */ -- cgit v1.2.3