[#58693908] Dedupe ListenAndServe error handling

Wrap it in a function, rather than using nearly identical anonymous
functions. `http.Handler` satifies the type. As an interface it also
satifies `nil`.

- http://golang.org/pkg/net/http/#Handler
- http://golang.org/ref/spec#The_zero_value

Thanks @nickstenning