diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-09-21 22:43:19 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-09-22 15:01:03 +0100 |
commit | e8808f8eb4e53a0a92f9e723c33f0ef7f072451c (patch) | |
tree | 27281dff7518a55c10722d5ac136e630767fefef /sal/qa | |
parent | 08dbc9b657697b74e3dcdeff8a829ba7434b013b (diff) |
ensure contents are as expected
Diffstat (limited to 'sal/qa')
-rw-r--r-- | sal/qa/OStringBuffer/rtl_OStringBuffer.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx b/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx index ad2413663181..7384457ec48c 100644 --- a/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx +++ b/sal/qa/OStringBuffer/rtl_OStringBuffer.cxx @@ -2249,8 +2249,8 @@ namespace rtl_OStringBuffer ::rtl::OStringBuffer aStrBuf("hello world"); aStrBuf.append('\0'); - aStrBuf.append('\0'); - aStrBuf.append('\0'); + aStrBuf.append('\1'); + aStrBuf.append('\2'); aStrBuf.append("hello world"); @@ -2258,7 +2258,10 @@ namespace rtl_OStringBuffer ( "should be able to append nulls", aStrBuf.getLength() == - 2 * RTL_CONSTASCII_LENGTH("hello world") + 3 + 2 * RTL_CONSTASCII_LENGTH("hello world") + 3 && + aStrBuf[RTL_CONSTASCII_LENGTH("hello world")] == 0 && + aStrBuf[RTL_CONSTASCII_LENGTH("hello world")]+1 == 1 && + aStrBuf[RTL_CONSTASCII_LENGTH("hello world")]+2 == 2 ); } |