That's not relevant for a text node; libxml2 only uses it to signal output escaping and otherwise ignores it. In fact xmlGetName/xmlSetName seems to not work here (my initial implementation tried to use those).