aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Gierlings <[email protected]>2016-10-27 00:04:41 +0200
committerMatthias Gierlings <[email protected]>2016-10-27 00:04:41 +0200
commit475cff54ce16bbb7e65c277453cb634bd46417b2 (patch)
tree5bfd89a1407226c61c8be13c8822f174d732e5ec
parent1b9d13aed71152d61fab7e0ba016d1951909bac5 (diff)
Fixes randombit/botan#677
-rw-r--r--src/tests/test_rng.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/tests/test_rng.cpp b/src/tests/test_rng.cpp
index e815caf65..ff5d0b62e 100644
--- a/src/tests/test_rng.cpp
+++ b/src/tests/test_rng.cpp
@@ -447,7 +447,7 @@ class HMAC_DRBG_Unit_Tests : public Test
::close(fd[0]); // close read end in child
rng.randomize(&child_bytes[0], child_bytes.size());
count = counting_rng.randomize_count();
- ::write(fd[1], &count, sizeof(count));
+ ssize_t written = ::write(fd[1], &count, sizeof(count));
try {
rng.randomize(&child_bytes[0], child_bytes.size());
}
@@ -455,7 +455,8 @@ class HMAC_DRBG_Unit_Tests : public Test
{
fprintf(stderr, "%s", e.what());
}
- ::write(fd[1], &child_bytes[0], child_bytes.size());
+ written = ::write(fd[1], &child_bytes[0], child_bytes.size());
+ BOTAN_UNUSED(written);
::close(fd[1]); // close write end in child
::_exit(0);
}