diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-06-12 10:44:00 +0200 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-06-12 11:02:17 +0200 |
commit | e3b4202b45f3a52dbb61632a9133f2dd0c1da343 (patch) | |
tree | e960b53135a0c8bdca4d3bd50ec6aa2691aed51d /lightdm-arctica-greeter-session | |
parent | ccba9e587a8ac83061ae34a98c019d734a8b1f69 (diff) | |
download | arctica-greeter-e3b4202b45f3a52dbb61632a9133f2dd0c1da343.tar.gz arctica-greeter-e3b4202b45f3a52dbb61632a9133f2dd0c1da343.tar.bz2 arctica-greeter-e3b4202b45f3a52dbb61632a9133f2dd0c1da343.zip |
Make guest account support functional. Port various items from Ubuntu's LightDM package.
Diffstat (limited to 'lightdm-arctica-greeter-session')
-rwxr-xr-x | lightdm-arctica-greeter-session | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/lightdm-arctica-greeter-session b/lightdm-arctica-greeter-session new file mode 100755 index 0000000..536e0ae --- /dev/null +++ b/lightdm-arctica-greeter-session @@ -0,0 +1,36 @@ +#!/bin/sh +# -*- Mode: sh; indent-tabs-mode: nil; tab-width: 4 -*- +# +# Copyright (C) 2011 Canonical Ltd +# Author: Michael Terry <michael.terry@canonical.com> +# +# This program is free software: you can redistribute it and/or modify it under +# the terms of the GNU General Public License as published by the Free Software +# Foundation, version 3 of the License. +# +# See http://www.gnu.org/copyleft/gpl.html the full text of the license. + +# This wrapper merely ensures that dbus-daemon lives only as long as this +# script does. Otherwise, it's very easy for dbus-daemon to be autolaunched +# and detached from the greeter. + +trap cleanup TERM EXIT + +cleanup() +{ + trap - TERM EXIT + if [ -n "$DBUS_SESSION_BUS_PID" ]; then + kill "$DBUS_SESSION_BUS_PID" + fi + if [ -n "$CMD_PID" ]; then + kill "$CMD_PID" + fi + exit 0 +} + +eval `dbus-launch --sh-syntax` + +exec $@ & +CMD_PID=$! +wait $CMD_PID +CMD_PID= |