summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulien Nabet <serval2412@yahoo.fr>2011-08-03 00:09:53 +0200
committerJulien Nabet <serval2412@yahoo.fr>2011-08-03 00:11:40 +0200
commit713873eee687e6354f5632f5d992ab2d848dafa1 (patch)
tree526565e8b35105d4be0436ec33b78e44465b135d
parentdbc8c2464f81f9ccaec88a173611ca96aa4083cf (diff)
2 fixes in OSL_DEBUG part with ByteString
-rw-r--r--sc/source/core/data/cell2.cxx29
-rw-r--r--sc/source/filter/starcalc/scflt.cxx2
2 files changed, 16 insertions, 15 deletions
diff --git a/sc/source/core/data/cell2.cxx b/sc/source/core/data/cell2.cxx
index d28ace58a..158930ed3 100644
--- a/sc/source/core/data/cell2.cxx
+++ b/sc/source/core/data/cell2.cxx
@@ -54,6 +54,7 @@
#include "externalrefmgr.hxx"
#include "scitems.hxx"
#include "patattr.hxx"
+#include <rtl/strbuf.hxx>
using namespace formula;
@@ -684,22 +685,22 @@ sal_uInt16 ScFormulaCell::GetMatrixEdge( ScAddress& rOrgPos )
#if OSL_DEBUG_LEVEL > 0
else
{
- String aTmp;
- ByteString aMsg( "broken Matrix, Pos: " );
+ rtl::OUString aTmp;
+ rtl::OStringBuffer aMsg( "broken Matrix, Pos: " );
aPos.Format( aTmp, SCA_VALID_COL | SCA_VALID_ROW, pDocument );
- aMsg += ByteString( aTmp, RTL_TEXTENCODING_ASCII_US );
- aMsg += ", MatOrg: ";
+ aMsg.append(rtl::OUStringToOString(aTmp, RTL_TEXTENCODING_UTF8 ));
+ aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatOrg: "));
aOrg.Format( aTmp, SCA_VALID_COL | SCA_VALID_ROW, pDocument );
- aMsg += ByteString( aTmp, RTL_TEXTENCODING_ASCII_US );
- aMsg += ", MatCols: ";
- aMsg += ByteString::CreateFromInt32( nC );
- aMsg += ", MatRows: ";
- aMsg += ByteString::CreateFromInt32( nR );
- aMsg += ", DiffCols: ";
- aMsg += ByteString::CreateFromInt32( dC );
- aMsg += ", DiffRows: ";
- aMsg += ByteString::CreateFromInt32( dR );
- OSL_FAIL( aMsg.GetBuffer() );
+ aMsg.append(rtl::OUStringToOString(aTmp, RTL_TEXTENCODING_UTF8 ));
+ aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatCols: "));
+ aMsg.append(static_cast<sal_Int32>( nC ));
+ aMsg.append(RTL_CONSTASCII_STRINGPARAM(", MatRows: "));
+ aMsg.append(static_cast<sal_Int32>( nR ));
+ aMsg.append(RTL_CONSTASCII_STRINGPARAM(", DiffCols: "));
+ aMsg.append(static_cast<sal_Int32>( dC ));
+ aMsg.append(RTL_CONSTASCII_STRINGPARAM(", DiffRows: "));
+ aMsg.append(static_cast<sal_Int32>( dR ));
+ OSL_FAIL( aMsg.makeStringAndClear().getStr());
}
#endif
return nEdges;
diff --git a/sc/source/filter/starcalc/scflt.cxx b/sc/source/filter/starcalc/scflt.cxx
index daf80257a..15f1628fc 100644
--- a/sc/source/filter/starcalc/scflt.cxx
+++ b/sc/source/filter/starcalc/scflt.cxx
@@ -1003,7 +1003,7 @@ sal_uLong Sc10Import::Import()
#if OSL_DEBUG_LEVEL > 0
if (nError)
{
- OSL_FAIL( ByteString::CreateFromInt32( nError ).GetBuffer() );
+ OSL_FAIL( rtl::OString::valueOf(static_cast<sal_Int32>(nError)).getStr());
}
#endif