]> Cypherpunks repositories - gostls13.git/commit
database/sql: check to see if ctx is cancelable before await
authorDaniel Theophanes <kardianos@gmail.com>
Mon, 26 Mar 2018 00:19:47 +0000 (17:19 -0700)
committerDaniel Theophanes <kardianos@gmail.com>
Tue, 27 Mar 2018 18:40:46 +0000 (18:40 +0000)
commit6e59c73a9fe4eab3e09c6287f69c48837580dbb4
tree15df07f569c86caedecf0d7b4801853fba6501b7
parent377a2cb2d20f37f259ca533c7a4b026dbbf8e585
database/sql: check to see if ctx is cancelable before await

Prevent queries from starting a goroutine if the context is
not able to be canceled.

Fixes #23879

Change-Id: I392047bd53d7f796219dd12ee11b07303658fdaf
Reviewed-on: https://go-review.googlesource.com/102478
Run-TryBot: Daniel Theophanes <kardianos@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Yasuhiro MATSUMOTO <mattn.jp@gmail.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/database/sql/sql.go