Change internal storage media path in storage_get_directory() 71/184571/1 accepted/tizen/4.0/unified/20180719.160930 submit/tizen_4.0/20180719.024335
authorHyotaek Shim <hyotaek.shim@samsung.com>
Thu, 19 Jul 2018 02:16:24 +0000 (11:16 +0900)
committerHyotaek Shim <hyotaek.shim@samsung.com>
Thu, 19 Jul 2018 02:18:49 +0000 (02:18 +0000)
Before: /opt/usr/media
After: /opt/usr/home/UID/media

Change-Id: Ida39777ac40587719beb8d28b8f04172c98900e5
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
src/storage-internal.c

index 7f5d359..0dadec9 100755 (executable)
@@ -15,6 +15,8 @@
  */
 
 
+#include <unistd.h>
+#include <sys/types.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -61,11 +63,7 @@ static int internal_get_space(unsigned long long *total, unsigned long long *ava
 static const char *internal_get_root(void)
 {
        const char *ret;
-
-       if (is_compat_bind_mount())
-               ret = COMPAT_DIR;
-       else
-               ret = tzplatform_getenv(TZ_USER_CONTENT);
+       ret = tzplatform_uid_getenv(getuid(), TZ_USER_CONTENT);
 
        return ret;
 }