kopia lustrzana https://github.com/Hamlib/Hamlib
Fix FILE* leak in test7400ADC.c
rodzic
2bb002a4bc
commit
8823325c55
|
@ -45,6 +45,7 @@ int read_calibration(int buf[NUM_CHANNELS][2])
|
|||
|
||||
if (fread(cal, NUM_CHANNELS * 4, 1, f) == 1)
|
||||
{
|
||||
fclose(f);
|
||||
for (j = 0; j < 2; j++)
|
||||
for (i = 0; i < NUM_CHANNELS; i++)
|
||||
{
|
||||
|
@ -67,6 +68,8 @@ empty_calibration:
|
|||
|
||||
printf("/etc/ADC-calibration.dat not found or it's not readable\n");
|
||||
|
||||
fclose(f);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue