From 48d94e10a7aaa9f9c0e7ef3bc02dada967719bef Mon Sep 17 00:00:00 2001 From: Deve Date: Sat, 7 Oct 2017 21:35:38 +0200 Subject: [PATCH] Use separate os name for android stats --- src/config/hardware_stats.cpp | 7 ++++++- src/online/http_request.cpp | 2 ++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/config/hardware_stats.cpp b/src/config/hardware_stats.cpp index d3f532f86..219670ef1 100644 --- a/src/config/hardware_stats.cpp +++ b/src/config/hardware_stats.cpp @@ -294,7 +294,12 @@ void reportHardwareStats() #else json.add("os_macosx", 0); #endif -#ifdef __linux__ +#ifdef ANDROID + json.add("os_android", 1); +#else + json.add("os_android", 0); +#endif +#if defined(__linux__) && !defined(ANDROID) json.add("os_linux", 1); json.add("os_unix", 1); #else diff --git a/src/online/http_request.cpp b/src/online/http_request.cpp index 5402a4f6c..728500df8 100644 --- a/src/online/http_request.cpp +++ b/src/online/http_request.cpp @@ -274,6 +274,8 @@ namespace Online uagent += (std::string)" (Macintosh)"; #elif defined(__FreeBSD__) uagent += (std::string)" (FreeBSD)"; + #elif defined(ANDROID) + uagent += (std::string)" (Android)"; #elif defined(linux) uagent += (std::string)" (Linux)"; #else