msxml3/tests: Null-terminate a string before A->W conversion (Valgrind).

This commit is contained in:
Nikolay Sivov 2014-05-04 20:33:18 +04:00 committed by Alexandre Julliard
parent 30410d48fd
commit 1742449ad8
1 changed files with 4 additions and 1 deletions

View File

@ -3297,8 +3297,9 @@ static void test_mxwriter_flush(void)
ok(pos2.QuadPart == 0, "expected stream beginning\n");
len = 2048;
buff = HeapAlloc(GetProcessHeap(), 0, len);
buff = HeapAlloc(GetProcessHeap(), 0, len+1);
memset(buff, 'A', len);
buff[len] = 0;
hr = ISAXContentHandler_characters(content, _bstr_(buff), len);
EXPECT_HR(hr, S_OK);
@ -3344,6 +3345,7 @@ todo_wine
ok(pos2.QuadPart == 0, "expected stream beginning\n");
memset(buff, 'A', len);
buff[len] = 0;
hr = ISAXContentHandler_characters(content, _bstr_(buff), len - 8);
EXPECT_HR(hr, S_OK);
@ -3368,6 +3370,7 @@ todo_wine
EXPECT_HR(hr, S_OK);
memset(buff, 'A', len);
buff[len] = 0;
hr = ISAXContentHandler_characters(content, _bstr_(buff), len);
EXPECT_HR(hr, S_OK);