mirror of
https://github.com/cjdenio/crossword.git
synced 2026-10-03 11:06:19 +00:00
fix 100% cpu usage
This commit is contained in:
2 files changed
+6
-3
No files matched your search
@@ -1,6 +1,6 @@
|
||||
all: bin/crossword bin/ssh
|
||||
all: bin/crossword bin/crossword-ssh
|
||||
|
||||
bin/crossword: main.go puz/puz.go game/game.go
|
||||
go build -o $@ .
|
||||
bin/ssh: ssh/main.go puz/puz.go game/game.go
|
||||
bin/crossword-ssh: ssh/main.go puz/puz.go game/game.go
|
||||
go build -o $@ ./ssh
|
||||
+4
-1
@@ -56,7 +56,10 @@ func main() {
|
||||
})
|
||||
|
||||
for {
|
||||
scanner.Scan()
|
||||
ok := scanner.Scan()
|
||||
if !ok {
|
||||
break
|
||||
}
|
||||
buffer := scanner.Bytes()
|
||||
|
||||
exited := state.HandleInput(buffer)
|
||||
|
||||
Reference in new issue
Block a user