mirror of
https://github.com/ergochat/ergo.git
synced 2024-12-26 04:32:36 +01:00
touch should respect destroyed
This commit is contained in:
parent
e0e61907ce
commit
541a40b056
@ -50,6 +50,10 @@ func NewClient(server *Server, conn net.Conn) *Client {
|
||||
}
|
||||
|
||||
func (client *Client) Touch() {
|
||||
if client.destroyed {
|
||||
return
|
||||
}
|
||||
|
||||
client.atime = time.Now()
|
||||
|
||||
if client.quitTimer != nil {
|
||||
|
@ -66,7 +66,7 @@ func (socket *Socket) Write(lines []string) error {
|
||||
}
|
||||
|
||||
func (socket *Socket) readLines() {
|
||||
for !socket.closed {
|
||||
for {
|
||||
line, err := socket.reader.ReadString('\n')
|
||||
if err != nil {
|
||||
if DEBUG_NET {
|
||||
|
Loading…
Reference in New Issue
Block a user