From dd0d76be5fa86490d030dd8bb36aec54b4a752f8 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Sun, 21 Jul 2019 12:08:22 +0200 Subject: osmo_get_rand_id(): Avoid dead code by proper #if/#else/#endif Change-Id: I34e465dead179487f7d4508e0e6ecf0e838c6eb7 Closes: CID#177910 --- src/gsm/gsm_utils.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/gsm/gsm_utils.c b/src/gsm/gsm_utils.c index f154c2b6..365920fa 100644 --- a/src/gsm/gsm_utils.c +++ b/src/gsm/gsm_utils.c @@ -466,8 +466,9 @@ int osmo_get_rand_id(uint8_t *out, size_t len) if (rc < 0) { #if (USE_GNUTLS) return gnutls_rnd(GNUTLS_RND_RANDOM, out, len); -#endif +#else return -errno; +#endif } /* getrandom() failed partially due to signal interruption: -- cgit v1.2.3