Nikolay Sivov : winhttp/tests: Add a couple of return value tests ( Coverity).

Alexandre Julliard julliard at winehq.org
Mon Feb 4 13:29:53 CST 2019


Module: wine
Branch: master
Commit: 2dc1c967d5928e11428d5fa75ffdaceac79654fa
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=2dc1c967d5928e11428d5fa75ffdaceac79654fa

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Thu Jan 31 23:31:46 2019 +0300

winhttp/tests: Add a couple of return value tests (Coverity).

Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winhttp/tests/winhttp.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/dlls/winhttp/tests/winhttp.c b/dlls/winhttp/tests/winhttp.c
index 91a9d53..3a28acf 100644
--- a/dlls/winhttp/tests/winhttp.c
+++ b/dlls/winhttp/tests/winhttp.c
@@ -3206,6 +3206,7 @@ static void test_multiple_reads(int port)
             char *buf = HeapAlloc( GetProcessHeap(), 0, len + 1 );
 
             ret = WinHttpReadData( req, buf, len, &bytes_read );
+            ok(ret, "WinHttpReadData failed: %u.\n", GetLastError());
             ok( len == bytes_read, "only got %u of %u available\n", bytes_read, len );
 
             HeapFree( GetProcessHeap(), 0, buf );
@@ -4699,6 +4700,7 @@ static void test_chunked_read(void)
             char *buf = HeapAlloc( GetProcessHeap(), 0, len + 1 );
 
             ret = WinHttpReadData( req, buf, len, &bytes_read );
+            ok(ret, "WinHttpReadData failed: %u.\n", GetLastError());
 
             buf[bytes_read] = 0;
             trace( "WinHttpReadData -> %d %u\n", ret, bytes_read );




More information about the wine-cvs mailing list