]> Cypherpunks repositories - gostls13.git/commitdiff
http: clarify ServeHTTP return
authorRuss Cox <rsc@golang.org>
Fri, 12 Feb 2010 22:27:44 +0000 (14:27 -0800)
committerRuss Cox <rsc@golang.org>
Fri, 12 Feb 2010 22:27:44 +0000 (14:27 -0800)
Fixes #580.

R=adg
CC=golang-dev
https://golang.org/cl/207086

src/pkg/http/server.go

index f9771f9b410c8ef4688fd3f508de7212af44a1f2..f0b608ddebffb3bb465865e89689239d53b365c3 100644 (file)
@@ -32,6 +32,11 @@ var (
 // Objects implementing the Handler interface can be
 // registered to serve a particular path or subtree
 // in the HTTP server.
+//
+// ServeHTTP should write reply headers and data to the Conn
+// and then return.  Returning signals that the request is finished
+// and that the HTTP server can move on to the next request on
+// the connection.
 type Handler interface {
        ServeHTTP(*Conn, *Request)
 }