gocql/gocql — pull request #179 by nemothekid (2014-06-12 17:38:13+00:00)
Title: executeBatch can cause a dead lock to a nil deref causing c.prepMu not to be unlocked. 

Currently in a high load situation `flight` or `flight.info` can be nil when execute batch is called (the prepareStatement call can take a long time or even timeout, during this time flight.info can be nil).

As executebatch searches for the prepared statement to reset, it can come across such a statement and panic. This panic causes `c.prepMu` not to be unlocked causing a dead lock.