diff options
author | arseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640> | 2009-10-20 19:21:34 +0000 |
---|---|---|
committer | arseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640> | 2009-10-20 19:21:34 +0000 |
commit | 5624befce1d64824efe7f57ef02b62a7be934404 (patch) | |
tree | dbfb04340772eecfe31fab68260202115f5ee847 /src | |
parent | 02cb7bf6854193881cec1bffca8f2ddca58fef06 (diff) |
Fixed node_pi and node_declaration copying
git-svn-id: http://pugixml.googlecode.com/svn/trunk@160 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'src')
-rw-r--r-- | src/pugixml.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp index c309544..1061447 100644 --- a/src/pugixml.cpp +++ b/src/pugixml.cpp @@ -1668,13 +1668,20 @@ namespace case node_pcdata:
case node_cdata:
case node_comment:
+ dest.set_value(source.value());
+ break;
+
case node_pi:
+ dest.set_name(source.name());
dest.set_value(source.value());
break;
case node_declaration:
dest.set_name(source.name());
- dest.set_value(source.value());
+
+ for (xml_attribute a = source.first_attribute(); a; a = a.next_attribute())
+ dest.append_attribute(a.name()).set_value(a.value());
+
break;
default:
|