diff mbox series

random: remove write-only variable random_entropy_file_read

Message ID 1534956548-8088-5-git-send-email-andrei.otcheretianski@intel.com
State Accepted
Headers show
Series random: remove write-only variable random_entropy_file_read | expand

Commit Message

Otcheretianski, Andrei Aug. 22, 2018, 4:49 p.m. UTC
From: Johannes Berg <johannes.berg@intel.com>

This variable is never read, so it's not needed. Remove it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 src/crypto/random.c | 2 --
 1 file changed, 2 deletions(-)

Comments

Jouni Malinen Sept. 2, 2018, 2:40 p.m. UTC | #1
On Wed, Aug 22, 2018 at 07:49:06PM +0300, Andrei Otcheretianski wrote:
> This variable is never read, so it's not needed. Remove it.

Thanks, applied.
diff mbox series

Patch

diff --git a/src/crypto/random.c b/src/crypto/random.c
index fb92417..c278d9c 100644
--- a/src/crypto/random.c
+++ b/src/crypto/random.c
@@ -54,7 +54,6 @@  static int random_fd = -1;
 static unsigned int own_pool_ready = 0;
 #define RANDOM_ENTROPY_SIZE 20
 static char *random_entropy_file = NULL;
-static int random_entropy_file_read = 0;
 
 #define MIN_COLLECT_ENTROPY 1000
 static unsigned int entropy = 0;
@@ -357,7 +356,6 @@  static void random_read_entropy(void)
 
 	own_pool_ready = (u8) buf[0];
 	random_add_randomness(buf + 1, RANDOM_ENTROPY_SIZE);
-	random_entropy_file_read = 1;
 	os_free(buf);
 	wpa_printf(MSG_DEBUG, "random: Added entropy from %s "
 		   "(own_pool_ready=%u)",