Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Stone <michael@laptop.org>2009-02-27 00:05:43 (GMT)
committer Michael Stone <michael@laptop.org>2009-02-27 00:05:43 (GMT)
commit1e876d9b6b1cd28600eb680b88248ae2cfb84620 (patch)
tree8f92096569eebe5179c2688dee24c7206f2782f7
parent133f11f354e7e54acf4c5f1f5be7cd474b015e55 (diff)
Supply reasonable default values when [X,ICE]AUTHORITY are unset.
-rwxr-xr-xrainbow/bin/rainbow-sugarize3
1 files changed, 3 insertions, 0 deletions
diff --git a/rainbow/bin/rainbow-sugarize b/rainbow/bin/rainbow-sugarize
index 5b5662e..b350479 100755
--- a/rainbow/bin/rainbow-sugarize
+++ b/rainbow/bin/rainbow-sugarize
@@ -51,6 +51,9 @@ def main():
# We want to use xauth generate $DISPLAY . untrusted, but we don't have
# XSECURITY enabled. <MS>
+ environ.setdefault('XAUTHORITY', join(h_o, '.Xauthority'))
+ environ.setdefault('ICEAUTHORITY', join(h_o, '.ICEauthority'))
+
x_cookie_path = join(h_i, '.Xauthority')
make_dirs(dirname(x_cookie_path), getuid(), getgid(), 0777)
copyfile(environ['XAUTHORITY'], x_cookie_path)