From 6ab37ae0d09de50adb5a77bbd3d836425868292b Mon Sep 17 00:00:00 2001 From: Khosrow Afroozeh Date: Thu, 11 Jun 2015 12:23:25 +0200 Subject: [PATCH] Corrected Recordset Lock Sequence --- recordset.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recordset.go b/recordset.go index dabef304..f41d3f21 100644 --- a/recordset.go +++ b/recordset.go @@ -132,9 +132,9 @@ func (rcs *Recordset) signalEnd() { } func (rcs *Recordset) sendError(err error) { + rcs.chanLock.Lock() + defer rcs.chanLock.Unlock() if rcs.IsActive() { - rcs.chanLock.Lock() - defer rcs.chanLock.Unlock() rcs.Errors <- err } }