Skip to content

Commit

Permalink
Avoid writing to output feed if it has been closed
Browse files Browse the repository at this point in the history
Checkin the correct file this time
  • Loading branch information
manik committed Feb 6, 2015
1 parent 3151afa commit 467f1dd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions upr.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,11 @@ func (feed *UprFeed) forwardUprEvents(nodeFeed *FeedInfo, killSwitch chan bool,
killSwitch <- true
return
}
if feed.outputClosed == true {
// someone closed the node feed
log.Printf("Node need closed, returning from forwardUprEvent")
return
}
feed.output <- event
if event.Status == gomemcached.NOT_MY_VBUCKET {
log.Printf(" Got a not my vbucket error !! ")
Expand Down

0 comments on commit 467f1dd

Please sign in to comment.