net/nfp: fix possible resource leak
Fixes: c7e9729da6
("net/nfp: support CPP")
Signed-off-by: Yangchao Zhou <zhouyates@gmail.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
This commit is contained in:
parent
4b954bb167
commit
687790cf9a
@ -815,6 +815,7 @@ nfp6000_set_barsz(struct nfp_pcie_user *desc)
|
||||
|
||||
if (fscanf(fp, "0x%lx 0x%lx 0x%lx", &start, &end, &flags) == 0) {
|
||||
printf("error reading resource file for bar size\n");
|
||||
fclose(fp);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user