Browse Source

constants: Remove unused constants.

We may re-add MaxReplyLength later as a variable config option, similar to mammon.
tags/v0.2.0
Daniel Oaks 7 years ago
parent
commit
09802f7181
2 changed files with 2 additions and 4 deletions
  1. 1
    3
      irc/constants.go
  2. 1
    1
      irc/websocket.go

+ 1
- 3
irc/constants.go View File

@@ -8,9 +8,7 @@ package irc
8 8
 import "fmt"
9 9
 
10 10
 const (
11
-	SEM_VER       = "0.2.0-unreleased"
12
-	CRLF          = "\r\n"
13
-	MAX_REPLY_LEN = 512 - len(CRLF)
11
+	SEM_VER = "0.2.0-unreleased"
14 12
 )
15 13
 
16 14
 var (

+ 1
- 1
irc/websocket.go View File

@@ -32,7 +32,7 @@ type WSContainer struct {
32 32
 func (this WSContainer) Read(msg []byte) (int, error) {
33 33
 	ty, bytes, err := this.ReadMessage()
34 34
 	if ty == websocket.TextMessage {
35
-		n := copy(msg, []byte(string(bytes)+CRLF+CRLF))
35
+		n := copy(msg, []byte(string(bytes)+"\r\n\r\n"))
36 36
 		return n, err
37 37
 	}
38 38
 	// Binary, and other kinds of messages, are thrown away.

Loading…
Cancel
Save