on xenial help sign in
Fix restart unity8 from inside the phone more than two times

Fixes: #1487946 Approved by: Michał Sawicz

commite2e5c105eb30755040e31e876ee22d6d0918e95a authorAlbert Astals Cid <albert.astals@canonical.com> dateMon 7 Sep 2015, 14:05 (11 years ago) parent17cb6be7a4c6b1
1 file changed+6−6
data/unity8.conf+6−6
data/unity8.conf+6−6
@@ -16,12 +16,12 @@ pre-start script
1616 initctl set-env UNITY_MIR_EMITS_SIGSTOP=1
1717
1818 if [ -n "$MIR_SOCKET" ]; then
19− if [ -z "$UNITY_MIR_SOCKET" ]; then
20− # Save original value of MIR_SOCKET in case we are restarted,
21− # as we modify the variable for future jobs, including ourself.
22− UNITY_MIR_SOCKET=$MIR_SOCKET
23− initctl set-env --global UNITY_MIR_SOCKET=$UNITY_MIR_SOCKET
24− fi
19+ # FIXME Create an autopilot test that makes sure start+stop and restart
20+ # work fine at least 2 times
21+ # Save original value of MIR_SOCKET in case we are stopped,
22+ # as we modify the variable for future jobs, including ourself.
23+ UNITY_MIR_SOCKET=$(initctl get-env --global MIR_SOCKET)
24+ initctl set-env --global UNITY_MIR_SOCKET=$UNITY_MIR_SOCKET
2525
2626 # Point unity8 at unity-system-compositor
2727 MIR_SERVER_FILE=$XDG_RUNTIME_DIR/mir_socket