Skip to content

Commit 0c0609c

Browse files
committed
add missing close on output chan
1 parent 9487daa commit 0c0609c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

gitdiff/parser.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ func Parse(r io.Reader) (<-chan *File, error) {
2020
out := make(chan *File)
2121

2222
if err := p.Next(); err != nil {
23+
close(out)
2324
if err == io.EOF {
2425
return out, nil
2526
}

0 commit comments

Comments
 (0)