From 3cd5a69b65c86eab4bf262258a88cde62065cc7d Mon Sep 17 00:00:00 2001 From: Norman Feske Date: Mon, 6 Jan 2025 16:05:58 +0100 Subject: [PATCH] base: make Xml_node publicly noncopyable This patch limits the Xml_node's copy constructor for internal use only. Fixes #5411 --- repos/base/include/util/xml_node.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/repos/base/include/util/xml_node.h b/repos/base/include/util/xml_node.h index 466654ceb0..9a82e77454 100644 --- a/repos/base/include/util/xml_node.h +++ b/repos/base/include/util/xml_node.h @@ -205,6 +205,19 @@ class Genode::Xml_node { private: + Xml_node(Xml_node const &other) + : + _addr(other._addr), _max_len(other._max_len), _tags(other._tags) + { } + + Xml_node &operator = (Xml_node const &other) + { + _addr = other._addr; + _max_len = other._max_len; + _tags = other._tags; + return *this; + } + using Token = Xml_attribute::Token; /**