bool _is_internet_feature_supported(void)
{
- static bool __is_checked = false;
- static bool __is_supported = true;
-
- if (!__is_checked) {
- char *profile = NULL;
- int ret = system_info_get_platform_string("http://tizen.org/feature/profile", &profile);
- if (ret == SYSTEM_INFO_ERROR_NONE && profile && *profile) {
- _LOG("profile = %s", profile);
-
- /* if wearable, check internet feature in addition */
- if (!strcmp("wearable", profile))
- ret = system_info_get_platform_bool("http://tizen.org/feature/network.internet", &__is_supported);
-
- if (profile)
- free(profile);
-
- /* set the flag which means feature checked */
- __is_checked = (ret == SYSTEM_INFO_ERROR_NONE);
- }
+ bool __is_supported = true;
+ char *profile = NULL;
+ int ret = system_info_get_platform_string("http://tizen.org/feature/profile", &profile);
+ if (ret == SYSTEM_INFO_ERROR_NONE && profile && *profile) {
+ if (!strcmp("wearable", profile))
+ ret = system_info_get_platform_bool("http://tizen.org/feature/network.internet", &__is_supported);
}
-
- _LOG("__is_checked = %d, __is_supported = %d", __is_checked, __is_supported);
-
+ if (profile)
+ free(profile);
return __is_supported;
-}
\ No newline at end of file
+}