Merge branch 'develop' of github-kali.github.com:kalikaneko/leap_common into develop
authorKali Kaneko <kali@leap.se>
Wed, 20 Mar 2013 15:27:20 +0000 (00:27 +0900)
committerKali Kaneko <kali@leap.se>
Wed, 20 Mar 2013 15:27:20 +0000 (00:27 +0900)
1  2 
src/leap/common/files.py

diff --combined src/leap/common/files.py
  #
  # You should have received a copy of the GNU General Public License
  # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 -
  """
  Implements file helper methods
  """
  
 +import errno
 +import logging
  import os
  import stat
 -import logging
  import time
 -import errno
  
  logger = logging.getLogger(__name__)
  
@@@ -111,7 -112,7 +111,7 @@@ def which(name, flags=os.X_OK, path_ext
      result = []
      exts = filter(None, os.environ.get('PATHEXT', '').split(os.pathsep))
      path = os.environ.get('PATH', None)
-     path += ":" + path_extension
+     path = path_extension + os.pathsep + path
      if path is None:
          return []
      parts = path.split(os.pathsep)