diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-08-07 09:13:47 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-08-07 16:14:45 +0100 |
commit | aac04652fda01b0299e17087b151f07d6115e894 (patch) | |
tree | 26a71ba651eb138d81f538b0d43b66f8da8e305d /basic | |
parent | db95e0b75903a34a1b88a3701334e154f32eeceb (diff) |
String::AllocBuffer replacements
Change-Id: I278cd66fb4819721bb473796c28598aaf04eb123
Diffstat (limited to 'basic')
-rw-r--r-- | basic/source/sbx/sbxscan.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/basic/source/sbx/sbxscan.cxx b/basic/source/sbx/sbxscan.cxx index 9a47d8e67689..32db97fba4e8 100644 --- a/basic/source/sbx/sbxscan.cxx +++ b/basic/source/sbx/sbxscan.cxx @@ -785,9 +785,10 @@ void SbxValue::Format( XubString& rRes, const XubString* pFmt ) const if( nMin < 10 && aFmtStr.EqualsIgnoreCaseAscii( VBAFORMAT_NN ) ) { // Minute in two digits - sal_Unicode* p = rRes.AllocBuffer( 2 ); - *p++ = '0'; - *p = sal_Unicode( '0' + nMin ); + sal_Unicode aBuf[2]; + aBuf[0] = '0'; + aBuf[1] = '0' + nMin; + rRes = rtl::OUString(aBuf, SAL_N_ELEMENTS(aBuf)); } else { |