Changeset 237 in code for trunk/user.go
- Timestamp:
- Apr 6, 2020, 5:11:26 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/user.go
r231 r237 3 3 import ( 4 4 "fmt" 5 "sync"6 5 "time" 7 6 … … 53 52 stopped chan struct{} 54 53 54 conn *upstreamConn 55 55 history map[string]uint64 56 56 lastError error 57 58 lock sync.Mutex59 conn *upstreamConn60 57 } 61 58 … … 122 119 123 120 func (net *network) upstream() *upstreamConn { 124 net.lock.Lock()125 defer net.lock.Unlock()126 121 return net.conn 127 122 } … … 233 228 uc := e.uc 234 229 235 uc.network.lock.Lock()236 230 uc.network.conn = uc 237 uc.network.lock.Unlock()238 231 239 232 uc.updateAway() … … 246 239 uc := e.uc 247 240 248 uc.network.lock.Lock()249 241 uc.network.conn = nil 250 uc.network.lock.Unlock()251 242 252 243 for _, ml := range uc.messageLoggers {
Note:
See TracChangeset
for help on using the changeset viewer.