Skip to content

Commit

Permalink
Remove unused lock (#9709)
Browse files Browse the repository at this point in the history
  • Loading branch information
zeripath authored Jan 11, 2020
1 parent edd3177 commit 960ac36
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions modules/queue/queue_disk_channel.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ package queue

import (
"context"
"sync"
"time"

"code.gitea.io/gitea/modules/log"
Expand Down Expand Up @@ -33,6 +34,7 @@ type PersistableChannelQueueConfiguration struct {
type PersistableChannelQueue struct {
*ChannelQueue
delayedStarter
lock sync.Mutex
closed chan struct{}
}

Expand Down
2 changes: 1 addition & 1 deletion modules/queue/queue_wrapped.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ type WrappedQueueConfiguration struct {
}

type delayedStarter struct {
lock sync.Mutex
internal Queue
underlying Type
cfg interface{}
Expand Down Expand Up @@ -89,6 +88,7 @@ func (q *delayedStarter) setInternal(atShutdown func(context.Context, func()), h
// WrappedQueue wraps a delayed starting queue
type WrappedQueue struct {
delayedStarter
lock sync.Mutex
handle HandlerFunc
exemplar interface{}
channel chan Data
Expand Down

0 comments on commit 960ac36

Please sign in to comment.