Fix worker termination handling

Fixes issue #102.
This commit is contained in:
kortschak 2014-08-26 14:20:37 +09:30
parent 62e7037f20
commit 73dbfc9461
3 changed files with 26 additions and 37 deletions

View file

@ -26,9 +26,9 @@ import (
)
type worker struct {
ts graph.TripleStore
env *otto.Otto
envLock sync.Mutex
ts graph.TripleStore
env *otto.Otto
sync.Mutex
results chan interface{}
shape map[string]interface{}
@ -36,7 +36,7 @@ type worker struct {
count int
limit int
kill chan struct{}
kill <-chan struct{}
}
func newWorker(ts graph.TripleStore) *worker {