From ed5a54e4abb678fd25060adc76a8c8c2bc0b00f3 Mon Sep 17 00:00:00 2001 From: badaix Date: Sun, 19 Mar 2017 20:47:09 +0100 Subject: [PATCH] fix getOS --- common/utils.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/utils.h b/common/utils.h index 1df44d6e..7d060e46 100644 --- a/common/utils.h +++ b/common/utils.h @@ -190,7 +190,7 @@ static std::string getOS() #endif if (os.empty()) { - os = trim_copy(execGetOutput("cat /etc/os-release /etc/openwrt_release |grep -e PRETTY_NAME -e DISTRIB_DESCRIPTION")); + os = trim_copy(execGetOutput("grep /etc/os-release /etc/openwrt_release -e PRETTY_NAME -e DISTRIB_DESCRIPTION")); if (os.find("=") != std::string::npos) { os = trim_copy(os.substr(os.find("=") + 1));