diff lisp/progmodes/python.el @ 80753:54fa0c487055

(run-python): Remove '' from sys.path.
author Romain Francoise <romain@orebokech.com>
date Sun, 24 Aug 2008 19:47:23 +0000
parents 0681f498ce1a
children 76e75acf7e4e
line wrap: on
line diff
--- a/lisp/progmodes/python.el	Sat Aug 23 18:54:05 2008 +0000
+++ b/lisp/progmodes/python.el	Sun Aug 24 19:47:23 2008 +0000
@@ -1355,7 +1355,9 @@
   ;; invoked.  Would support multiple processes better.
   (when (or new (not (comint-check-proc python-buffer)))
     (with-current-buffer
-        (let* ((cmdlist (append (python-args-to-list cmd) '("-i")))
+	(let* ((cmdlist
+		(append (python-args-to-list cmd)
+			'("-i" "-c" "import sys; sys.path.remove('')")))
                (path (getenv "PYTHONPATH"))
                (process-environment	; to import emacs.py
                 (cons (concat "PYTHONPATH=" data-directory