(cherry picked from commit 9cd1d03b33d07befeb94f4d6546111d782fa94d8)
This commit is contained in:
coderstory 2020-12-25 00:04:28 +08:00 committed by 双草酸酯
parent cc546647cb
commit 265d7c1604
1 changed files with 2 additions and 3 deletions

View File

@ -20,9 +20,8 @@ namespace edxp {
}
static inline std::string GetAndroidBrand() {
std::string prop_value;
prop_value.reserve(PROP_VALUE_MAX);
__system_property_get("ro.product.brand", prop_value.data());
char prop_value[PROP_VALUE_MAX];
__system_property_get("ro.product.brand", prop_value);
return prop_value;
}