Browse Source

Fix build issues

tags/v0.11.0-alpha
Daniel Oaks 6 years ago
parent
commit
ac99e82192
5 changed files with 9 additions and 9 deletions
  1. 2
    2
      irc/client.go
  2. 1
    1
      irc/dline.go
  3. 1
    1
      irc/idletimer.go
  4. 1
    1
      irc/kline.go
  5. 4
    4
      irc/server.go

+ 2
- 2
irc/client.go View File

@@ -211,7 +211,7 @@ func (client *Client) run() {
211 211
 			}
212 212
 		}
213 213
 		// ensure client connection gets closed
214
-		client.destroy()
214
+		client.destroy(false)
215 215
 	}()
216 216
 
217 217
 	client.idletimer = NewIdleTimer(client)
@@ -395,7 +395,7 @@ func (client *Client) TryResume() {
395 395
 
396 396
 	server.clients.byNick[oldnick] = client
397 397
 
398
-	oldClient.destroy()
398
+	oldClient.destroy(false)
399 399
 }
400 400
 
401 401
 // IdleTime returns how long this client's been idle.

+ 1
- 1
irc/dline.go View File

@@ -406,7 +406,7 @@ func dlineHandler(server *Server, client *Client, msg ircmsg.IrcMessage) bool {
406 406
 				killClient = true
407 407
 			} else {
408 408
 				// if mcl == client, we kill them below
409
-				mcl.destroy()
409
+				mcl.destroy(false)
410 410
 			}
411 411
 		}
412 412
 

+ 1
- 1
irc/idletimer.go View File

@@ -104,7 +104,7 @@ func (it *IdleTimer) processTimeout() {
104 104
 		it.client.Ping()
105 105
 	} else {
106 106
 		it.client.Quit(it.quitMessage(previousState))
107
-		it.client.destroy()
107
+		it.client.destroy(false)
108 108
 	}
109 109
 }
110 110
 

+ 1
- 1
irc/kline.go View File

@@ -298,7 +298,7 @@ func klineHandler(server *Server, client *Client, msg ircmsg.IrcMessage) bool {
298 298
 				killClient = true
299 299
 			} else {
300 300
 				// if mcl == client, we kill them below
301
-				mcl.destroy()
301
+				mcl.destroy(false)
302 302
 			}
303 303
 		}
304 304
 

+ 4
- 4
irc/server.go View File

@@ -424,7 +424,7 @@ func (server *Server) tryRegister(c *Client) {
424 424
 			reason += fmt.Sprintf(" [%s]", info.Time.Duration.String())
425 425
 		}
426 426
 		c.Quit(fmt.Sprintf("You are banned from this server (%s)", reason))
427
-		c.destroy()
427
+		c.destroy(false)
428 428
 		return
429 429
 	}
430 430
 
@@ -2016,7 +2016,7 @@ func killHandler(server *Server, client *Client, msg ircmsg.IrcMessage) bool {
2016 2016
 	target.exitedSnomaskSent = true
2017 2017
 
2018 2018
 	target.Quit(quitMsg)
2019
-	target.destroy()
2019
+	target.destroy(false)
2020 2020
 	return false
2021 2021
 }
2022 2022
 
@@ -2093,13 +2093,13 @@ func resumeHandler(server *Server, client *Client, msg ircmsg.IrcMessage) bool {
2093 2093
 
2094 2094
 	var timestamp *time.Time
2095 2095
 	if 1 < len(msg.Params) {
2096
-		timestamp, err := time.Parse("2006-01-02T15:04:05.999Z", msg.Params[1])
2096
+		timestamp, err = time.Parse("2006-01-02T15:04:05.999Z", msg.Params[1])
2097 2097
 		if err != nil {
2098 2098
 			client.Send(nil, server.name, ERR_CANNOT_RESUME, oldnick, "Timestamp is not in 2006-01-02T15:04:05.999Z format, ignoring it")
2099 2099
 		}
2100 2100
 	}
2101 2101
 
2102
-	client.resumeDetails = ResumeDetails{
2102
+	client.resumeDetails = &ResumeDetails{
2103 2103
 		OldNick:   oldnick,
2104 2104
 		Timestamp: timestamp,
2105 2105
 	}

Loading…
Cancel
Save