merge from 3.2
diff --git a/Lib/ntpath.py b/Lib/ntpath.py
index 419342d..ec8a7ab 100644
--- a/Lib/ntpath.py
+++ b/Lib/ntpath.py
@@ -654,7 +654,7 @@
     # Non-Windows operating systems fake this method with an XP
     # approximation.
     def _getfinalpathname(f):
-        return abspath(f)
+        return normcase(abspath(f))
 
 def samefile(f1, f2):
     "Test whether two pathnames reference the same actual file"
diff --git a/Misc/NEWS b/Misc/NEWS
index 420ed8e..2436709 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -140,6 +140,9 @@
 Library
 -------
 
+- ntpath.samefile failed to notice that "a.txt" and "A.TXT" refer to the same
+  file on Windows XP. As noticed in issue #10684.
+
 - Issue #12000: When a SSL certificate has a subjectAltName without any
   dNSName entry, ssl.match_hostname() should use the subject's commonName.
   Patch by Nicolas Bareil.