summaryrefslogtreecommitdiff
path: root/include/rtl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-01-05 13:52:17 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-01-05 13:52:17 +0100
commitc03d803a723e3325b210346126115457e914f605 (patch)
tree4de546352d3bd7f8534b07128cf946638790d93c /include/rtl
parent910817d7364253c8ed0dc876e5e38fdc707e0ee8 (diff)
Replace side-effect--only uses of makeStringAndClear() with setLength(0)
Change-Id: Iaf8011f1bd6a10b324653899b7f51458f7d0b68a
Diffstat (limited to 'include/rtl')
-rw-r--r--include/rtl/strbuf.hxx2
-rw-r--r--include/rtl/ustrbuf.hxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/include/rtl/strbuf.hxx b/include/rtl/strbuf.hxx
index 90bf41b6fd54..8c9148b3e984 100644
--- a/include/rtl/strbuf.hxx
+++ b/include/rtl/strbuf.hxx
@@ -301,7 +301,7 @@ public:
@return the string previously contained in the buffer.
*/
- OString makeStringAndClear()
+ SAL_WARN_UNUSED_RESULT OString makeStringAndClear()
{
OString aRet( pData );
rtl_string_new(&pData);
diff --git a/include/rtl/ustrbuf.hxx b/include/rtl/ustrbuf.hxx
index 7a9448d02d5d..4665d20b1d35 100644
--- a/include/rtl/ustrbuf.hxx
+++ b/include/rtl/ustrbuf.hxx
@@ -336,7 +336,7 @@ public:
@return the string previously contained in the buffer.
*/
- OUString makeStringAndClear()
+ SAL_WARN_UNUSED_RESULT OUString makeStringAndClear()
{
return OUString(
rtl_uStringBuffer_makeStringAndClear( &pData, &nCapacity ),