Skip to content

Commit

Permalink
Use nogvl_dbsqlok
Browse files Browse the repository at this point in the history
  • Loading branch information
andyundso committed Oct 23, 2024
1 parent 7a0562e commit 30f0541
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ext/tiny_tds/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -305,10 +305,10 @@ static VALUE rb_tinytds_execute(VALUE self, VALUE sql) {
if (cwrap->userdata->dbsql_sent) {
// if we do not run dbsqlok, FreeTDS will throw an error
// Attempt to initiate a new Adaptive Server operation with results pending
// note that both of these operations are blocking as we do not have access to these
// "NOGVL" methods from result.c
if (cwrap->userdata->dbsqlok_sent == 0) {
dbsqlok(cwrap->client);
if(nogvl_dbsqlok(cwrap->client) != SUCCEED) {
rb_raise(cTinyTdsError, "unable to acknowledge previous results with server");
}
}

dbcancel(cwrap->client);
Expand Down

0 comments on commit 30f0541

Please sign in to comment.