summaryrefslogtreecommitdiff
path: root/xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 15:21:29 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 15:21:29 +0200
commitbada6666c70977a058755ccf232e7d67b24adeed (patch)
tree1e92d50cebce96abaf9bce19e36026c47f77b9ba /xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx
parenteaf34adcbd8095bc6d1f3371b1227f654c7b19fc (diff)
New upstream release
Diffstat (limited to 'xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx')
-rw-r--r--xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx20
1 files changed, 12 insertions, 8 deletions
diff --git a/xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx b/xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx
index b5cfaf9..e4d6f5b 100644
--- a/xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx
+++ b/xsd/libxsd/xsd/cxx/xml/std-memory-manager.hxx
@@ -1,6 +1,5 @@
// file : xsd/cxx/xml/std-memory-manager.hxx
-// author : Boris Kolpackov <boris@codesynthesis.com>
-// copyright : Copyright (c) 2005-2010 Code Synthesis Tools CC
+// copyright : Copyright (c) 2005-2014 Code Synthesis Tools CC
// license : GNU GPL v2 + exceptions; see accompanying LICENSE file
#ifndef XSD_CXX_XML_STD_MEMORY_MANAGER_HXX
@@ -18,12 +17,10 @@ namespace xsd
class std_memory_manager: public xercesc::MemoryManager
{
public:
+ // Xerces-C++ MemoryManager interface.
+ //
virtual void*
-#if _XERCES_VERSION >= 30000
allocate(XMLSize_t size)
-#else
- allocate(size_t size)
-#endif
{
return operator new (size);
}
@@ -35,13 +32,20 @@ namespace xsd
operator delete (p);
}
-#if _XERCES_VERSION >= 30000
virtual xercesc::MemoryManager*
getExceptionMemoryManager()
{
return xercesc::XMLPlatformUtils::fgMemoryManager;
}
-#endif
+
+ // Standard deleter interface.
+ //
+ void
+ operator() (void* p) const
+ {
+ if (p)
+ operator delete (p);
+ }
};
}
}