datastax/csharp-driver — pull request #13 by teddymaef (2014-03-07 01:25:56+00:00)
Title: fix bug in CassandraConnection to avoid the exceptions after disposed

This is a bug I found when simply loop and test the following case:

for (int i = 0; i < 100; ++i)
{
using (connectiion = new)
{
connection.open

execute command for simple insert
}
}

Exceptions are thrown from disposed CassandraConnection class instances. The detail of the exception is when already disposed, _socketStream.EndRead() throws exception when accessing disposed instance socket internally, So we need to check disposed first.