diff --git a/watchdog/handler.go b/watchdog/handler.go index 61d6618ae..5e71d5d6a 100644 --- a/watchdog/handler.go +++ b/watchdog/handler.go @@ -94,6 +94,9 @@ func pipeRequest(config *WatchdogConfig, w http.ResponseWriter, r *http.Request, var buildInputErr error requestBody, buildInputErr = buildFunctionInput(config, r) if buildInputErr != nil { + if config.writeDebug == true { + log.Printf("Error=%s, ReadLen=%d\n", buildInputErr.Error(), len(requestBody)) + } ri.headerWritten = true w.WriteHeader(http.StatusBadRequest) // I.e. "exit code 1"