From 0c293887d07ad819f737609e0e44abfc2c8f6ae0 Mon Sep 17 00:00:00 2001
From: yhirose <yuji.hirose.bug@gmail.com>
Date: Sun, 15 Sep 2019 09:15:21 -0400
Subject: [PATCH] Fixed problem with redirect

---
 httplib.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/httplib.h b/httplib.h
index d4b60b5..ae606d0 100644
--- a/httplib.h
+++ b/httplib.h
@@ -1568,6 +1568,7 @@ inline bool redirect(T &cli, const Request &req, Response &res,
   new_req.headers = req.headers;
   new_req.body = req.body;
   new_req.redirect_count = req.redirect_count - 1;
+  new_req.response_handler = req.response_handler;
   new_req.content_receiver = req.content_receiver;
   new_req.progress = req.progress;