Skip to content

Commit

Permalink
attempt to avoid race condition with active connections
Browse files Browse the repository at this point in the history
  • Loading branch information
brianmario committed Nov 16, 2011
1 parent 8118f31 commit a1ddafa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions ext/mysql2/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,7 @@ static VALUE rb_mysql_client_async_result(VALUE self) {

if (result == NULL) {
if (mysql_errno(wrapper->client) != 0) {
MARK_CONN_INACTIVE(self);
rb_raise_mysql2_error(wrapper);
}
// no data and no error, so query was not a SELECT
Expand Down

0 comments on commit a1ddafa

Please sign in to comment.