gitea/modules/queue
zeripath f305cffcaf
Prevent race in PersistableChannelUniqueQueue.Has () ()
Backport 

There is potentially a race with a slow starting internal
queue causing a NPE if Has is checked before the internal
queue has been setup.

This PR adds a lock on the Has() fn.

Fix 

Signed-off-by: Andrew Thornton <art27@cantab.net>

Co-authored-by: 6543 <6543@obermui.de>
..
bytefifo.go Add Unique Queue infrastructure and move TestPullRequests to this ()
helper.go Queue: Make WorkerPools and Queues flushable ()
manager.go Fix broken FlushAll ()
queue.go Add queue for code indexer ()
queue_bytefifo.go Add Unique Queue infrastructure and move TestPullRequests to this ()
queue_channel.go Add Unique Queue infrastructure and move TestPullRequests to this ()
queue_channel_test.go Fix Workerpool deadlock ()
queue_disk.go Allow common redis and leveldb connections ()
queue_disk_channel.go Add Unique Queue infrastructure and move TestPullRequests to this ()
queue_disk_channel_test.go use assignment in tests ()
queue_disk_test.go use assignment in tests ()
queue_redis.go Allow common redis and leveldb connections ()
queue_test.go Graceful Queues: Issue Indexing and Tasks ()
queue_wrapped.go Prevent timer leaks in Workerpool and others ()
setting.go Fix the issue reported on ()
unique_queue.go Add Unique Queue infrastructure and move TestPullRequests to this ()
unique_queue_channel.go Add Unique Queue infrastructure and move TestPullRequests to this ()
unique_queue_disk.go Allow common redis and leveldb connections ()
unique_queue_disk_channel.go Prevent race in PersistableChannelUniqueQueue.Has () ()
unique_queue_redis.go Allow common redis and leveldb connections ()
unique_queue_wrapped.go Add Unique Queue infrastructure and move TestPullRequests to this ()
workerpool.go Prevent timer leaks in Workerpool and others ()