summaryrefslogtreecommitdiff
path: root/meta/recipes-graphics
diff options
context:
space:
mode:
authorTom Hochstein <tom.hochstein@nxp.com>2016-06-09 14:27:06 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-12 23:42:40 +0100
commit9f539d03138817b7b740ed1895000704e4a475d0 (patch)
tree82f5aa3b0bd9730b32a6c0ff187161a6c8170248 /meta/recipes-graphics
parent537afef2209bef327a28234207d1ef7e4e596a6e (diff)
downloadopenembedded-core-9f539d03138817b7b740ed1895000704e4a475d0.tar.gz
openembedded-core-9f539d03138817b7b740ed1895000704e4a475d0.tar.bz2
openembedded-core-9f539d03138817b7b740ed1895000704e4a475d0.zip
weston-init: Don't change XDG_RUNTIME_DIR if it already exists
In the case that XDG_RUNTIME_DIR already exists, the mkdir --parents at least does nothing, but the chmod could overwrite the desired file mode settings. Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/recipes-graphics')
-rwxr-xr-xmeta/recipes-graphics/wayland/weston-init/weston-start6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/recipes-graphics/wayland/weston-init/weston-start b/meta/recipes-graphics/wayland/weston-init/weston-start
index 4b41576103..5b7604f930 100755
--- a/meta/recipes-graphics/wayland/weston-init/weston-start
+++ b/meta/recipes-graphics/wayland/weston-init/weston-start
@@ -65,8 +65,10 @@ fi
if test -z "$XDG_RUNTIME_DIR"; then
export XDG_RUNTIME_DIR=/run/user/`id -u`
- mkdir --parents $XDG_RUNTIME_DIR
- chmod 0700 $XDG_RUNTIME_DIR
+ if ! test -d "$XDG_RUNTIME_DIR"; then
+ mkdir --parents $XDG_RUNTIME_DIR
+ chmod 0700 $XDG_RUNTIME_DIR
+ fi
fi
exec openvt $openvt_args -- $launcher $weston_args --log=@LOCALSTATEDIR@/log/weston.log