[cpp-xmltooling COMMIT] in /branches/REL_1/xmltooling: base.h util/ParserPool.cpp

noreply at shibboleth.net noreply at shibboleth.net
Sun Dec 25 00:35:59 GMT 2011


Author: scantor
Date: Sun Dec 25 00:35:59 2011
New Revision: 949

URL: http://svn.shibboleth.net/view/cpp-xmltooling?rev=949&view=rev
Log:
Solaris fixes

Modified:
    branches/REL_1/xmltooling/base.h
    branches/REL_1/xmltooling/util/ParserPool.cpp

Modified: branches/REL_1/xmltooling/base.h
URL: http://svn.shibboleth.net/view/cpp-xmltooling/branches/REL_1/xmltooling/base.h?rev=949&r1=948&r2=949&view=diff
==============================================================================
--- branches/REL_1/xmltooling/base.h (original)
+++ branches/REL_1/xmltooling/base.h Sun Dec 25 00:35:59 2011
@@ -698,8 +698,9 @@
         } \
         void set##proper(int proper) { \
             try { \
-                xmltooling::xstring buf = boost::lexical_cast<xmltooling::xstring>(proper); \
-                set##proper(buf.c_str()); \
+                std::string buf(boost::lexical_cast<std::string>(proper)); \
+                xmltooling::auto_ptr_XMLCh widen(buf.c_str()); \
+                set##proper(widen.get()); \
             } \
             catch (boost::bad_lexical_cast&) { \
             } \
@@ -1253,8 +1254,9 @@
     XMLTOOLING_DOXYGEN(Sets proper.) \
     void set##proper(int proper) { \
         try { \
-            xmltooling::xstring buf = boost::lexical_cast<xmltooling::xstring>(proper); \
-            setTextContent(buf.c_str()); \
+            std::string buf(boost::lexical_cast<std::string>(proper)); \
+            xmltooling::auto_ptr_XMLCh widen(buf.c_str()); \
+            setTextContent(widen.get()); \
         } \
         catch (boost::bad_lexical_cast&) { \
         } \

Modified: branches/REL_1/xmltooling/util/ParserPool.cpp
URL: http://svn.shibboleth.net/view/cpp-xmltooling/branches/REL_1/xmltooling/util/ParserPool.cpp?rev=949&r1=948&r2=949&view=diff
==============================================================================
--- branches/REL_1/xmltooling/util/ParserPool.cpp (original)
+++ branches/REL_1/xmltooling/util/ParserPool.cpp Sun Dec 25 00:35:59 2011
@@ -244,8 +244,7 @@
     for_each(
         catpaths.begin(), catpaths.end(),
         // Call loadCatalog with an inner call to s->c_str() on each entry.
-        boost::bind(static_cast<bool (ParserPool::*)(const char*)>(&ParserPool::loadCatalog),
-            boost::ref(this), boost::bind(&string::c_str, _1))
+        boost::bind(static_cast<bool (ParserPool::*)(const char*)>(&ParserPool::loadCatalog), this, boost::bind(&string::c_str, _1))
         );
     return catpaths.begin() != catpaths.end();
 }



More information about the commits mailing list