diff --git a/server/WebApi.cpp b/server/WebApi.cpp index 4546657d..83409998 100755 --- a/server/WebApi.cpp +++ b/server/WebApi.cpp @@ -753,14 +753,14 @@ void installWebApi() { val["code"] = API::Success; auto &data = val["data"]; for (auto &info : info_list) { - auto obj = reinterpret_pointer_cast(info); + auto obj = static_pointer_cast(info); data.append(std::move(*obj)); } invoker(200, headerOut, val.toStyledString()); }, [](std::shared_ptr &&info) -> std::shared_ptr { auto obj = std::make_shared(); - auto session = reinterpret_pointer_cast(info); + auto session = static_pointer_cast(info); (*obj)["peer_ip"] = session->get_peer_ip(); (*obj)["peer_port"] = session->get_peer_port(); return obj;