msctf/tests: Return if the constructor fails. This avoids several clang warnings.

Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Huw Davies 2017-01-17 11:41:22 +00:00 committed by Alexandre Julliard
parent 5fb2267a78
commit aac4cc8fbb
1 changed files with 5 additions and 5 deletions

View File

@ -1550,11 +1550,11 @@ static void test_startSession(void)
ITfDocumentMgr_Release(dmtest);
hr = TextStoreACP_Constructor((IUnknown**)&ts);
if (SUCCEEDED(hr))
{
hr = ITfDocumentMgr_CreateContext(g_dm, cid, 0, (IUnknown*)ts, &cxt, &editCookie);
ok(SUCCEEDED(hr),"CreateContext Failed\n");
}
ok(SUCCEEDED(hr),"Constructor Failed\n");
if (FAILED(hr)) return;
hr = ITfDocumentMgr_CreateContext(g_dm, cid, 0, (IUnknown*)ts, &cxt, &editCookie);
ok(SUCCEEDED(hr),"CreateContext Failed\n");
hr = ITfDocumentMgr_CreateContext(g_dm, cid, 0, NULL, &cxt2, &editCookie);
ok(SUCCEEDED(hr),"CreateContext Failed\n");