diff --git a/src/components/memory.cpp b/src/components/memory.cpp index cb0f1cf..e118061 100644 --- a/src/components/memory.cpp +++ b/src/components/memory.cpp @@ -80,8 +80,3 @@ bool memory::getEasyMem(crow::json::wvalue& ret){ return true; } - -bool memory::getRawEasyMem(std::string& ret){ - std::ifstream f (procmempath); - -} diff --git a/src/components/memory.hpp b/src/components/memory.hpp index 32b0985..2609f7c 100644 --- a/src/components/memory.hpp +++ b/src/components/memory.hpp @@ -17,5 +17,4 @@ namespace memory{ bool getProcMem(crow::json::wvalue&); bool getRawProcMem(std::string&); bool getEasyMem(crow::json::wvalue&); - bool getRawEasyMem(std::string&); } diff --git a/src/routes.cpp b/src/routes.cpp index daadbc9..f074db5 100644 --- a/src/routes.cpp +++ b/src/routes.cpp @@ -24,19 +24,12 @@ void setRoutes(crow::SimpleApp& app){ } }); - CROW_ROUTE(app, "/mem")([](const crow::request& req){ + CROW_ROUTE(app, "/mem")([](){ bool status; - std::string accept = req.get_header_value("Accept"); - std::transform(accept.begin(), accept.end(), accept.begin(), ::tolower); - - if(accept == "text/plain"){ - accept.clear(); - } else { - crow::json::wvalue json; - status = memory::getEasyMem(json); - return crow::response(status ? 200 : 503, json.dump()); - } + crow::json::wvalue json; + status = memory::getEasyMem(json); + return crow::response(status ? 200 : 503, json.dump()); });