From: Kunhoon Baik Date: Thu, 1 Sep 2016 13:39:20 +0000 (+0900) Subject: Bind 2.4 apps directory to user app directory for compatibility X-Git-Tag: submit/tizen/20160904.234158^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9afcd97e50f16bc489015ac6b4cd669e75434b2b;p=platform%2Fadaptation%2Fsystem-plugin.git Bind 2.4 apps directory to user app directory for compatibility Change-Id: Ieb817310c970b9fd40249f583421d2862cd1c908 --- diff --git a/src/systemd-user-helper/systemd-user-helper.c b/src/systemd-user-helper/systemd-user-helper.c index f6911d6..2012e9d 100644 --- a/src/systemd-user-helper/systemd-user-helper.c +++ b/src/systemd-user-helper/systemd-user-helper.c @@ -26,7 +26,9 @@ #include +// For compatibility, Using hard-coded path #define LEGACY_CONTENTS_DIR "/opt/usr/media" +#define LEGACY_APPS_DIR "/opt/usr/apps" #define LAZYMOUNT_LIB "/usr/lib/liblazymount.so.0" #define CONTAINER_LIB "/usr/lib/security/pam_krate.so" @@ -69,6 +71,14 @@ static int normal_user_postprocess(char *username) fprintf(stderr, "user content bind mount failed - %d\n",errno); return r; } + + r = mount(tzplatform_getenv(TZ_USER_APP), + LEGACY_APPS_DIR, NULL, MS_BIND, NULL); + if (r < 0) { + fprintf(stderr, "user app bind mount failed - %d\n",errno); + return r; + } + return 0; }