Fix deadlock
This commit is contained in:
@@ -38,6 +38,7 @@ func hsh(files []string) chan result {
|
|||||||
r := make(chan result)
|
r := make(chan result)
|
||||||
go func() {
|
go func() {
|
||||||
r <- result{err: fmt.Errorf("unsupported algorithm: %v", *algo)}
|
r <- result{err: fmt.Errorf("unsupported algorithm: %v", *algo)}
|
||||||
|
close(r)
|
||||||
}()
|
}()
|
||||||
return r
|
return r
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user