From 33a99c140e866856b5bf1a44ef7bfced89444c3c Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Mon, 24 Sep 2007 10:37:14 +0000 Subject: [PATCH] Change directory to that of the .exe if in Windows. --- src/common.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common.py b/src/common.py index f2401a61e..cac8134e3 100644 --- a/src/common.py +++ b/src/common.py @@ -53,7 +53,8 @@ else: import sys if hasattr(sys, "frozen"): - INSTALL_PREFIX = '' + INSTALL_PREFIX = '' + os.chdir(os.path.dirname(unicode(sys.executable, sys.getfilesystemencoding( )))) else: # the necessary substitutions are made at installation time INSTALL_PREFIX = '@datadir@'