Skip to content

Commit a40b1d5

Browse files
authored
SNOW-1313927 Do not close channel twice in async handling (#1098)
1 parent 04153f3 commit a40b1d5

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

async.go

-2
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,13 @@ func (sr *snowflakeRestful) getAsync(
102102
if isMultiStmt(&respd.Data) {
103103
if err = sc.handleMultiQuery(ctx, respd.Data, rows); err != nil {
104104
rows.errChannel <- err
105-
close(rows.errChannel)
106105
return err
107106
}
108107
} else {
109108
rows.addDownloader(populateChunkDownloader(ctx, sc, respd.Data))
110109
}
111110
if err = rows.ChunkDownloader.start(); err != nil {
112111
rows.errChannel <- err
113-
close(rows.errChannel)
114112
return err
115113
}
116114
rows.errChannel <- nil // mark query status complete

0 commit comments

Comments
 (0)