Fixed a bug opening a file without extension via the command line. 5_3_x

Thu, 04 Apr 2013 19:08:42 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 04 Apr 2013 19:08:42 +0200
branch
5_3_x
changeset 2558
bc79bae54496
parent 2557
bf643d8b37fc
child 2561
b396baae6aa7

Fixed a bug opening a file without extension via the command line.

UI/UserInterface.py file | annotate | diff | comparison | revisions
diff -r bf643d8b37fc -r bc79bae54496 UI/UserInterface.py
--- a/UI/UserInterface.py	Mon Apr 01 17:56:48 2013 +0200
+++ b/UI/UserInterface.py	Thu Apr 04 19:08:42 2013 +0200
@@ -1034,9 +1034,12 @@
                 else:
                     argsStr = "{0} {1}".format(argsStr, arg)
                 continue
-
-            ext = os.path.splitext(arg)[1]
-            ext = os.path.normcase(ext)
+            
+            try:
+                ext = os.path.splitext(arg)[1]
+                ext = os.path.normcase(ext)
+            except IndexError:
+                ext = ""
 
             if ext in ['.e4p']:
                 self.project.openProject(arg)

eric ide

mercurial