diff --git a/mercurial/posix.py b/mercurial/posix.py
--- a/mercurial/posix.py
+++ b/mercurial/posix.py
@@ -300,7 +300,7 @@ def checklink(path):
 def checkosfilename(path):
     '''Check that the base-relative path is a valid filename on this platform.
     Returns None if the path is ok, or a UI string describing the problem.'''
-    pass # on posix platforms, every path is ok
+    return None # on posix platforms, every path is ok
 
 def setbinary(fd):
     pass