From: Karel Zak Date: Mon, 2 Oct 2017 09:27:59 +0000 (+0200) Subject: lib/randutils: remove superfluous continue X-Git-Tag: v2.31-rc2~13 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=43dc89344940da43ae53c768b9e85635b77e0b50;p=thirdparty%2Futil-linux.git lib/randutils: remove superfluous continue Addresses: https://github.com/karelzak/util-linux/commit/fa949792072530b49ef5760d7ecd6d250c66e35f#commitcomment-24678670 Signed-off-by: Karel Zak --- diff --git a/lib/randutils.c b/lib/randutils.c index b7e8e47e01..e1c4059e19 100644 --- a/lib/randutils.c +++ b/lib/randutils.c @@ -109,13 +109,10 @@ void random_get_bytes(void *buf, size_t nbytes) n -= x; cp += x; lose_counter = 0; - } else if (errno == ENOSYS) { /* kernel without getrandom() */ + } else if (errno == ENOSYS) /* kernel without getrandom() */ + break; + else if (lose_counter++ > 16) /* entropy problem? */ break; - } else { - if (lose_counter++ > 16) /* entropy problem? */ - break; - continue; - } } if (errno == ENOSYS)