elm_config: Fix wrong type conversion 85/243085/1
authorWoochanlee <wc0917.lee@samsung.com>
Thu, 3 Sep 2020 05:01:25 +0000 (14:01 +0900)
committerWoochanlee <wc0917.lee@samsung.com>
Thu, 3 Sep 2020 05:01:25 +0000 (14:01 +0900)
User set the env value as "0" or "1"
but in previouse case the result was always true.

Change-Id: If51ce58070e125141f51e10515330dc7bc61e69e

src/lib/elementary/elm_config.c

index 58f366e..bb9ea87 100644 (file)
@@ -3478,11 +3478,11 @@ _env_get(void)
    s = _getenv_once("ELM_AUTO_NORENDER_WITHDRAWN");
    if (s) _elm_config->auto_norender_withdrawn = !!atoi(s);
    s = _getenv_once("ELM_AUTO_NORENDER_ICONIFIED_SAME_AS_WITHDRAWN");
-   if (s) _elm_config->auto_norender_iconified_same_as_withdrawn = EINA_TRUE;
+   if (s) _elm_config->auto_norender_iconified_same_as_withdrawn = !!atoi(s);
    s = _getenv_once("ELM_AUTO_FLUSH_WITHDRAWN");
-   if (s) _elm_config->auto_flush_withdrawn = EINA_TRUE;
+   if (s) _elm_config->auto_flush_withdrawn = !!atoi(s);
    s = _getenv_once("ELM_AUTO_DUMP_WIDTHDRAWN");
-   if (s) _elm_config->auto_dump_withdrawn = EINA_TRUE;
+   if (s) _elm_config->auto_dump_withdrawn = !!atoi(s);
 
    s = _getenv_once("ELM_INDICATOR_SERVICE_0");
    if (s) eina_stringshare_replace(&_elm_config->indicator_service_0, s);