influxql: fix scanner bug caused by double unread

pull/1300/head
David Norton 2015-01-06 19:56:04 -05:00
parent 3b649d3e63
commit 5ea393f5ac
1 changed files with 0 additions and 2 deletions

View File

@ -46,7 +46,6 @@ func (s *Scanner) Scan() (tok Token, pos Pos, lit string) {
ch1, _ := s.r.read()
s.r.unread()
if isDigit(ch1) {
s.r.unread()
return s.scanNumber()
}
return DOT, pos, ""
@ -241,7 +240,6 @@ func (s *Scanner) scanNumber() (tok Token, pos Pos, lit string) {
}
s.r.unread()
}
return NUMBER, pos, buf.String()
}