We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8fb9c94 commit ab20588Copy full SHA for ab20588
src/common/platform_utils.hpp
@@ -342,6 +342,16 @@ static inline std::string PlatformUtilsGetSecureEnv(const char* /* name */) {
342
return {};
343
}
344
345
+static inline bool PlatformUtilsGetBoolSysProp(const char* name, bool default_value) {
346
+ bool result = default_value;
347
+ char value[PROP_VALUE_MAX] = {};
348
+ if (__system_property_get(name, value) != 0) {
349
+ result = (value[0] == 't');
350
+ }
351
+
352
+ return result;
353
+}
354
355
// Intended to be only used as a fallback on Android, with a more open, "native" technique used in most cases
356
static inline bool PlatformGetGlobalRuntimeFileName(uint16_t major_version, std::string& file_name) {
357
// Prefix for the runtime JSON file name
0 commit comments