mirror of
https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake.git
synced 2025-10-13 20:11:19 -04:00
Second async test for Broker's proxy answer handler
This commit is contained in:
parent
032ab6bcb8
commit
ee5f4558af
2 changed files with 42 additions and 3 deletions
|
@ -210,7 +210,7 @@ func answerHandler(ctx *BrokerContext, w http.ResponseWriter, r *http.Request) {
|
|||
return
|
||||
}
|
||||
body, err := ioutil.ReadAll(r.Body)
|
||||
if nil != err {
|
||||
if nil != err || nil == body || len(body) <= 0 {
|
||||
log.Println("Invalid data.")
|
||||
w.WriteHeader(http.StatusBadRequest)
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue