Explorar el Código

capexample: listen on localhost.

Dmitry Chestnykh hace 11 años
padre
commit
e965f48e07
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      capexample/main.go

+ 1 - 1
capexample/main.go

@@ -46,7 +46,7 @@ func main() {
 	http.HandleFunc("/process", processFormHandler)
 	http.Handle("/captcha/", captcha.Server(captcha.StdWidth, captcha.StdHeight))
 	fmt.Println("Server is at localhost:8666")
-	if err := http.ListenAndServe(":8666", nil); err != nil {
+	if err := http.ListenAndServe("localhost:8666", nil); err != nil {
 		log.Fatal(err)
 	}
 }