riched20/tests: Fix a SysAllocString leak.

This commit is contained in:
Jactry Zeng 2014-03-13 20:49:18 +08:00 committed by Alexandre Julliard
parent 02af74400f
commit fa2c509243
1 changed files with 3 additions and 1 deletions

View File

@ -190,7 +190,7 @@ static void test_ITextDocument_Open(void)
int tomNumSingle = sizeof(tomConstantsSingle)/sizeof(tomConstantsSingle[0]); int tomNumSingle = sizeof(tomConstantsSingle)/sizeof(tomConstantsSingle[0]);
int tomNumMulti = sizeof(tomConstantsMulti)/sizeof(tomConstantsMulti[0]); int tomNumMulti = sizeof(tomConstantsMulti)/sizeof(tomConstantsMulti[0]);
int i; int i;
VariantInit(&testfile);
V_VT(&testfile) = VT_BSTR; V_VT(&testfile) = VT_BSTR;
V_BSTR(&testfile) = SysAllocString(filename); V_BSTR(&testfile) = SysAllocString(filename);
@ -378,6 +378,8 @@ static void test_ITextDocument_Open(void)
todo_wine ok(result == 0, "ITextDocument_Open: Test UTF-16 set wrong text: Result: %s\n", wine_dbgstr_w(bufUnicode)); todo_wine ok(result == 0, "ITextDocument_Open: Test UTF-16 set wrong text: Result: %s\n", wine_dbgstr_w(bufUnicode));
release_interfaces(&w, &reOle, &txtDoc, &txtSel); release_interfaces(&w, &reOle, &txtDoc, &txtSel);
DeleteFileW(filename); DeleteFileW(filename);
VariantClear(&testfile);
} }
START_TEST(richole) START_TEST(richole)