diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2010-12-06 22:12:05 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2010-12-06 22:12:05 +0000 |
commit | c8534543c994eb03ecae71064dae88cc320f2e09 (patch) | |
tree | d345f036b4718830ec7d885671dec5e55a3bd03b /src/core/attr.c | |
parent | 7f6a523284959458c26cd27d9386329223ba920c (diff) | |
download | libdom-c8534543c994eb03ecae71064dae88cc320f2e09.tar.gz libdom-c8534543c994eb03ecae71064dae88cc320f2e09.tar.bz2 |
Fix copy constructors to actually copy all members, instead of leaving the majority of them uninitialised
svn path=/trunk/libdom/; revision=11023
Diffstat (limited to 'src/core/attr.c')
-rw-r--r-- | src/core/attr.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/core/attr.c b/src/core/attr.c index 4cd9e76..b280057 100644 --- a/src/core/attr.c +++ b/src/core/attr.c @@ -780,9 +780,18 @@ dom_exception _dom_attr_copy(struct dom_node_internal *new, dom_attr *oa = (dom_attr *) old; na->specified = oa->specified; - na->is_id = oa->is_id; /* TODO: deal with dom_type_info, it get no definition ! */ + na->schema_type_info = NULL; + + na->is_id = oa->is_id; + + na->type = oa->type; + + na->value = oa->value; + + /* TODO: is this correct? */ + na->read_only = false; return _dom_node_copy(new, old); } |