mirror of
https://github.com/imgproxy/imgproxy.git
synced 2024-11-24 08:12:38 +02:00
fix: close file (#1274)
This commit is contained in:
parent
e4bf5e93fb
commit
27d9ebad38
@ -66,6 +66,7 @@ func StringSliceFile(s *[]string, filepath string) error {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("Can't open file %s\n", filepath)
|
return fmt.Errorf("Can't open file %s\n", filepath)
|
||||||
}
|
}
|
||||||
|
defer f.Close()
|
||||||
|
|
||||||
scanner := bufio.NewScanner(f)
|
scanner := bufio.NewScanner(f)
|
||||||
for scanner.Scan() {
|
for scanner.Scan() {
|
||||||
|
Loading…
Reference in New Issue
Block a user