fix bad patch for bounds check in previous
--HG-- branch : nmdc-ircfrontend
This commit is contained in:
parent
53b72e0cb0
commit
d21b18fc75
@ -133,12 +133,12 @@ func (s *Server) RunWorker() {
|
||||
|
||||
// Client sent a command
|
||||
fields := strings.Fields(string(line))
|
||||
if len(fields) < 2 {
|
||||
if len(fields) == 0 {
|
||||
return
|
||||
}
|
||||
|
||||
if strings.HasPrefix(fields[0], ":") {
|
||||
fields = fields[1:]
|
||||
fields[0] = fields[0][1:]
|
||||
}
|
||||
|
||||
s.handleCommand(strings.ToUpper(fields[0]), fields[1:])
|
||||
|
Loading…
Reference in New Issue
Block a user