From 36debbe80f5388b5dd08955bbeabc3da0e8caf1e Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Thu, 4 Sep 2014 17:10:45 +0200 Subject: [PATCH] kernel32/tests: Ensure that pipe tests read the full pipe content. --- dlls/kernel32/tests/pipe.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/dlls/kernel32/tests/pipe.c b/dlls/kernel32/tests/pipe.c index 157dc53e508..832b980d028 100644 --- a/dlls/kernel32/tests/pipe.c +++ b/dlls/kernel32/tests/pipe.c @@ -251,7 +251,9 @@ static void test_CreateNamedPipe(int pipemode) } pbuf = ibuf; ok(memcmp(obuf, pbuf, sizeof(obuf)) == 0, "content 5a check\n"); - + if (readden <= sizeof(obuf)) + ok(ReadFile(hFile, ibuf, sizeof(ibuf), &readden, NULL), "ReadFile\n"); + /* Multiple writes in the reverse direction */ /* the write of obuf2 from write4 should still be in the buffer */ ok(PeekNamedPipe(hnp, ibuf, sizeof(ibuf), &readden, &avail, NULL), "Peek6a\n"); @@ -281,6 +283,8 @@ static void test_CreateNamedPipe(int pipemode) } pbuf = ibuf; ok(memcmp(obuf, pbuf, sizeof(obuf)) == 0, "content 6a check\n"); + if (readden <= sizeof(obuf)) + ok(ReadFile(hnp, ibuf, sizeof(ibuf), &readden, NULL), "ReadFile\n"); } /* Picky conformance tests */