From 2162688ad3bf7e1765d8576e6a29fb5f17641f09 Mon Sep 17 00:00:00 2001 From: Michael Daumling Date: Tue, 22 Oct 2013 17:03:37 +0200 Subject: [PATCH] Issue #134: Change 3 methods to not being inlined. They reference the StrPair class, which is not exported, thus creating linker problems with tinyxml2 in a DLL. --- tinyxml2.cpp | 15 +++++++++++++++ tinyxml2.h | 14 +++++--------- 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/tinyxml2.cpp b/tinyxml2.cpp index 5611614..b890cb1 100755 --- a/tinyxml2.cpp +++ b/tinyxml2.cpp @@ -595,6 +595,10 @@ XMLNode::~XMLNode() } } +const char* XMLNode::Value() const +{ + return _value.GetStr(); +} void XMLNode::SetValue( const char* str, bool staticMem ) { @@ -1040,6 +1044,17 @@ bool XMLUnknown::Accept( XMLVisitor* visitor ) const } // --------- XMLAttribute ---------- // + +const char* XMLAttribute::Name() const +{ + return _name.GetStr(); +} + +const char* XMLAttribute::Value() const +{ + return _value.GetStr(); +} + char* XMLAttribute::ParseDeep( char* p, bool processEntities ) { // Parse using the name rules: bug fix, was using ParseText before diff --git a/tinyxml2.h b/tinyxml2.h index 6b29324..52f9180 100755 --- a/tinyxml2.h +++ b/tinyxml2.h @@ -643,9 +643,7 @@ public: Text: the text string @endverbatim */ - const char* Value() const { - return _value.GetStr(); - } + const char* Value() const; /** Set the Value of an XML node. @sa Value() @@ -1014,13 +1012,11 @@ class TINYXML2_LIB XMLAttribute friend class XMLElement; public: /// The name of the attribute. - const char* Name() const { - return _name.GetStr(); - } + const char* Name() const; + /// The value of the attribute. - const char* Value() const { - return _value.GetStr(); - } + const char* Value() const; + /// The next attribute in the list. const XMLAttribute* Next() const { return _next;