Merged revisions 85689 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r85689 | hirokazu.yamamoto | 2010-10-18 21:13:18 +0900 | 3 lines

  Issue #5117: Case normalization was needed on ntpath.relpath(). And
  fixed root directory issue on posixpath.relpath(). (Ported working fixes
  from ntpath)
........
diff --git a/Lib/posixpath.py b/Lib/posixpath.py
index d317ceb..64fe9df 100644
--- a/Lib/posixpath.py
+++ b/Lib/posixpath.py
@@ -444,8 +444,8 @@
     if start is None:
         start = curdir
 
-    start_list = abspath(start).split(sep)
-    path_list = abspath(path).split(sep)
+    start_list = [x for x in abspath(start).split(sep) if x]
+    path_list = [x for x in abspath(path).split(sep) if x]
 
     # Work out how much of the filepath is shared by start and path.
     i = len(commonprefix([start_list, path_list]))