|
|
@@ -4,10 +4,11 @@ import (
|
|
|
"log"
|
|
|
"net/http"
|
|
|
"pinguin/board"
|
|
|
+ "runtime"
|
|
|
)
|
|
|
|
|
|
func main() {
|
|
|
- //runtime.GOMAXPROCS(1)
|
|
|
+ runtime.GOMAXPROCS(runtime.NumCPU())
|
|
|
http.HandleFunc("/api/board", boardHandler)
|
|
|
http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
|
|
|
w.Write([]byte("Go battlecamp!"))
|