From da88fd722b12beed9fbb045aae8a834cf8df75a9 Mon Sep 17 00:00:00 2001 From: antao Date: Thu, 2 Aug 2018 16:15:53 +0800 Subject: [PATCH] fix a bug --- lib/src/HttpAppFramework.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/HttpAppFramework.cc b/lib/src/HttpAppFramework.cc index bfc72c68..2f312a48 100755 --- a/lib/src/HttpAppFramework.cc +++ b/lib/src/HttpAppFramework.cc @@ -439,7 +439,7 @@ void HttpAppFrameworkImpl::onAsyncRequest(const HttpRequestPtr& req,const std::f _sessionMapPtr->insert(session_id,std::make_shared< Session >(),_sessionTimeout); } } - ((HttpRequestImpl &)req).setSession((*_sessionMapPtr)[session_id]); + (std::dynamic_pointer_cast(req))->setSession((*_sessionMapPtr)[session_id]); } std::string path = req->path();