small fix for basenames of zero length
authorStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Sun, 5 Mar 2006 09:16:39 +0000 (09:16 +0000)
committerStefan Pluecken <stefan.pluecken@multimedia-labs.de>
Sun, 5 Mar 2006 09:16:39 +0000 (09:16 +0000)
lib/python/Tools/Directories.py

index 6c84216fe25bbe86c080d7a295232e340211f6ec..6b321c3299c7689096622aa4cb9ba440aa2af048 100644 (file)
@@ -47,7 +47,7 @@ def resolveFilename(scope, base = ""):
                if (not pathExists(defaultPaths[scope][0])):
                        os.mkdir(path[0])
                        
-       if base[0] == '/':
+       if len(base > 0) and base[0] == '/':
                path = ""
        
        if not fileExists(path[0] + base):