all repos — telegram-bot-api @ 9c399358c93e7e59818914ad7302f418d8365db4

Golang bindings for the Telegram Bot API

Merge pull request #211 from bcmk/close-body

Addressing too many open files error
Kirill Zhuharev zhuharev@users.noreply.github.com
Fri, 14 Dec 2018 21:00:14 +0300
commit

9c399358c93e7e59818914ad7302f418d8365db4

parent

9860bdfd3a171ceafb6e1eafa163482a6ef92643

1 files changed, 1 insertions(+), 0 deletions(-)

jump to
M bot.gobot.go

@@ -526,6 +526,7 @@ ch := make(chan Update, bot.Buffer)

http.HandleFunc(pattern, func(w http.ResponseWriter, r *http.Request) { bytes, _ := ioutil.ReadAll(r.Body) + r.Body.Close() var update Update json.Unmarshal(bytes, &update)