From 87846f64b5705f2759c157b80073fc841ecc0876 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Mon, 20 May 2024 21:38:53 +0200 Subject: [PATCH] avutil/random_seed: Avoid dead returns Fixes: CID1538296 Structurally dead code Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer --- libavutil/random_seed.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavutil/random_seed.c b/libavutil/random_seed.c index 6d399cee49..8a4e4f1fc0 100644 --- a/libavutil/random_seed.c +++ b/libavutil/random_seed.c @@ -158,10 +158,10 @@ int av_random_bytes(uint8_t* buf, size_t len) #elif CONFIG_OPENSSL if (RAND_bytes(buf, len) == 1) return 0; - err = AVERROR_EXTERNAL; -#endif - + return AVERROR_EXTERNAL; +#else return err; +#endif } uint32_t av_get_random_seed(void)