Author: hdu
Date: Fri Nov 29 15:13:41 2013
New Revision: 1546578

URL: http://svn.apache.org/r1546578
Log:
#i123068# allow OString argument for tools' DbgOut() function

The DbgOut() function is active especially in dbgutil-enabled builds.
For creating dynamic strings the rtl::OString is often used. Providing a
DbgOut() function which allows a direct OString argument helps is useful
in situations where dynamic string creation and DbgOut() are employed.

Modified:
    openoffice/trunk/main/sal/inc/rtl/string.hxx

Modified: openoffice/trunk/main/sal/inc/rtl/string.hxx
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/sal/inc/rtl/string.hxx?rev=1546578&r1=1546577&r2=1546578&view=diff
==============================================================================
--- openoffice/trunk/main/sal/inc/rtl/string.hxx (original)
+++ openoffice/trunk/main/sal/inc/rtl/string.hxx Fri Nov 29 15:13:41 2013
@@ -965,9 +965,11 @@ struct CStringHash
 
 } /* Namespace */
 
-/* Helper method to support OString messages in OSL_ENSURE */
+/* Helper methods to support OString messages in OSL_ENSURE, DBG_ERROR, 
DBG_WARN, DBG_TRACE, etc. */
 inline sal_Bool SAL_CALL osl_assertFailedLine( const sal_Char* pszFileName, 
sal_Int32 nLine, const ::rtl::OString& rMessage)
-{ return osl_assertFailedLine( pszFileName, nLine, rMessage.getStr()); }
+       { return osl_assertFailedLine( pszFileName, nLine, rMessage.getStr()); }
+inline void DbgOut( const rtl::OString& rMessage, sal_uInt16 nOutType, const 
sal_Char* pFileName, sal_uInt16 nLineNum )
+       { DbgOut( rMessage.getStr(), nOutType, pFileName, nLineNum); }
 
 #endif /* __cplusplus */
 


Reply via email to