From: Andrea Claudi Date: Sat, 7 Aug 2021 16:58:02 +0000 (+0200) Subject: lib: bpf_glue: remove useless assignment X-Git-Tag: v5.14.0~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1eacf12b58eb9907dc071f32238388ef3e254c0;p=thirdparty%2Fiproute2.git lib: bpf_glue: remove useless assignment The value of s used inside the cycle is the result of strstr(), so this assignment is useless. Signed-off-by: Andrea Claudi Signed-off-by: Stephen Hemminger --- diff --git a/lib/bpf_glue.c b/lib/bpf_glue.c index eaa9504f3..70d001840 100644 --- a/lib/bpf_glue.c +++ b/lib/bpf_glue.c @@ -63,7 +63,7 @@ const char *get_libbpf_version(void) if (fp == NULL) goto out; - while ((s = fgets(buf, sizeof(buf), fp)) != NULL) { + while (fgets(buf, sizeof(buf), fp) != NULL) { if ((s = strstr(buf, "libbpf.so.")) != NULL) { strncpy(_libbpf_version, s+10, sizeof(_libbpf_version)-1); strtok(_libbpf_version, "\n");