Skip to content
Commit 3a4f0cc6 authored by Shuah Khan's avatar Shuah Khan
Browse files

selftests:kvm: fix get_trans_hugepagesz() ignoring fscanf() return warn



Fix get_trans_hugepagesz() to check fscanf() return value to get rid
of the following warning:

lib/test_util.c: In function ‘get_trans_hugepagesz’:
lib/test_util.c:138:2: warning: ignoring return value of ‘fscanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  138 |  fscanf(f, "%ld", &size);
      |  ^~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent 39a71f71
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment