summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2013-11-21 20:32:46 -0500
committerKohei Yoshida <kohei.yoshida@collabora.com>2013-11-22 09:03:33 -0500
commit6087da0dd402013b7d67fe6754081e647fdc5f8c (patch)
treea7a8971d86e9d8dd3f1d844fa7c22410feb119ff /oox
parent151beeb0b234512768080da3441ebe40a46cd861 (diff)
getChar() to return a null-terminated char array.
No need to fetch string size with this change. Change-Id: Iae5f6c60430fc57985a0fec5bfec59727e5a8f0f
Diffstat (limited to 'oox')
-rw-r--r--oox/source/helper/attributelist.cxx14
1 files changed, 6 insertions, 8 deletions
diff --git a/oox/source/helper/attributelist.cxx b/oox/source/helper/attributelist.cxx
index e57dd1d26cf3..2efc3a3ed4ba 100644
--- a/oox/source/helper/attributelist.cxx
+++ b/oox/source/helper/attributelist.cxx
@@ -261,16 +261,14 @@ OUString AttributeList::getXString( sal_Int32 nAttrToken, const OUString& rDefau
return getXString( nAttrToken ).get( rDefault );
}
-AttributeList::Char AttributeList::getChar( sal_Int32 nAttrToken ) const
+const char* AttributeList::getChar( sal_Int32 nAttrToken ) const
{
- Char aRet;
- bool bValid = getAttribList()->getAsChar(nAttrToken, aRet.mpPos, aRet.mnSize);
+ const char* p = NULL;
+ bool bValid = getAttribList()->getAsChar(nAttrToken, p);
if (!bValid)
- {
- aRet.mpPos = NULL;
- aRet.mnSize = 0;
- }
- return aRet;
+ p = NULL;
+
+ return p;
}
double AttributeList::getDouble( sal_Int32 nAttrToken, double fDefault ) const