Skip to content

Commit

Permalink
bugfix:mmap pageQuery nil poniter
Browse files Browse the repository at this point in the history
 Please enter the commit message for your changes. Lines starting
	modified:   store/mmap/kite_mmap_store.go
  • Loading branch information
blackbeans committed Mar 25, 2015
1 parent 0f5b57a commit d463d69
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions store/mmap/kite_mmap_store.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ func (self *KiteMMapStore) Delete(messageId string) bool {
//根据kiteServer名称查询需要重投的消息 返回值为 是否还有更多、和本次返回的数据结果
func (self *KiteMMapStore) PageQueryEntity(hashKey string, kiteServer string, nextDeliveryTime int64, startIdx, limit int) (bool, []*MessageEntity) {
pe := make([]*MessageEntity, 0, limit+1)
self.lock.RLock()
defer self.lock.RUnlock()
for e := self.datalink.Back(); nil != e; e = e.Prev() {
entity := e.Value.(*MessageEntity)
if entity.NextDeliverTime <= nextDeliveryTime &&
Expand Down

0 comments on commit d463d69

Please sign in to comment.