Skip to content

Commit

Permalink
make sure we invalidate the closed FD in case it's value is reused on…
Browse files Browse the repository at this point in the history
… a new connection
  • Loading branch information
brianmario committed Oct 16, 2010
1 parent 6e5cda6 commit 841ee2b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions ext/mysql2/client.c
Expand Up @@ -144,6 +144,7 @@ static VALUE nogvl_close(void * ptr) {
if (!wrapper->closed) {
wrapper->closed = 1;
mysql_close(wrapper->client);
wrapper->client->net.fd = -1;
if (!wrapper->freed) {
free(wrapper->client);
}
Expand Down

0 comments on commit 841ee2b

Please sign in to comment.