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 <aclaudi@redhat.com> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
parent
50a4127022
commit
d1eacf12b5
|
|
@ -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");
|
||||
|
|
|
|||
Loading…
Reference in New Issue