summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2012-03-30 18:27:58 +0100
committerMichael Meeks <michael.meeks@suse.com>2012-04-02 13:51:55 +0100
commit1426d4432c59ef42f28642ec63e57517223eb32d (patch)
tree75b6d769d309b2564e6a730a278e9c1c126ce777 /tools
parent0f330ea25840690d05516adc20cfb3d1a9d33317 (diff)
sal: expose more stringbuffer related instrumentation points
Avoid ref/unref pair in makeStringAndClear, hook into the stringbuffer-like 'String' class to expose it's conversion to immutable strings, and fixup misc. missing instrumentation.
Diffstat (limited to 'tools')
-rw-r--r--tools/inc/tools/string.hxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/inc/tools/string.hxx b/tools/inc/tools/string.hxx
index 2d1e6a964954..edecd2f7e592 100644
--- a/tools/inc/tools/string.hxx
+++ b/tools/inc/tools/string.hxx
@@ -33,6 +33,7 @@
#include <osl/thread.h>
#include <rtl/textenc.h>
#include <rtl/textcvt.h>
+#include <rtl/ustrbuf.h>
#include <rtl/string.hxx>
#include <rtl/ustring.hxx>
#include "tools/toolsdllapi.h"
@@ -173,7 +174,8 @@ public:
operator rtl::OUString () const
{
- return rtl::OUString (reinterpret_cast<rtl_uString*>(mpData));
+ return rtl::OUString( rtl_uStringBuffer_refReturn(
+ reinterpret_cast<rtl_uString*>(mpData)), SAL_NO_ACQUIRE );
}
static UniString CreateFromAscii( const sal_Char* pAsciiStr );