summaryrefslogtreecommitdiff
path: root/startx.cpp
diff options
context:
space:
mode:
authorJeremy Huddleston <jeremyhu@freedesktop.org>2008-07-02 16:36:24 -0700
committerJeremy Huddleston <jeremyhu@freedesktop.org>2008-07-02 16:36:24 -0700
commit7d41013b0e295ec0444c2f9099679bb6018c812f (patch)
treef88e7e0499e4969f4a481ad16240b220091de8d8 /startx.cpp
parent9632367abd03108f3636b05e9f2fd92f5c28dabe (diff)
Apple: Using eval to protect people who have spaces in their home path.
Diffstat (limited to 'startx.cpp')
-rw-r--r--startx.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/startx.cpp b/startx.cpp
index 8950feb..5ff62a0 100644
--- a/startx.cpp
+++ b/startx.cpp
@@ -271,7 +271,11 @@ if [ x"$enable_xauth" = x1 ] ; then
xauth -q -f "$xserverauthfile" << EOF
add :$dummy . $mcookie
EOF
+#ifdef __APPLE__
+ serverargs=${serverargs}" -auth '"${xserverauthfile}"'"
+#else
serverargs=${serverargs}" -auth "${xserverauthfile}
+#endif
XCOMM now add the same credentials to the client authority file
XCOMM if '$displayname' already exists do not overwrite it as another
@@ -300,9 +304,15 @@ else
XINIT "$client" $clientargs -- "$server" $display $serverargs
fi
#else
+
+#ifdef __APPLE__
+eval XINIT \"$client\" $clientargs -- \"$server\" $display $serverargs
+#else
XINIT "$client" $clientargs -- "$server" $display $serverargs
#endif
+#endif
+
if [ x"$enable_xauth" = x1 ] ; then
if [ x"$removelist" != x ]; then
XAUTH remove $removelist