[meld] meldapp: Add better error reporting for invalid URI args



commit 5889b21db140246e43ff2fbc940120e34d6f05f2
Author: Kai Willadsen <kai willadsen gmail com>
Date:   Thu Jan 1 09:24:59 2015 +1000

    meldapp: Add better error reporting for invalid URI args

 meld/meldapp.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/meld/meldapp.py b/meld/meldapp.py
index 766c6b9..6f99a5a 100644
--- a/meld/meldapp.py
+++ b/meld/meldapp.py
@@ -321,6 +321,9 @@ class MeldApp(Gtk.Application):
             auto_merge = (
                 options.auto_merge if i == len(comparisons) - 1 else False)
             try:
+                for p, f in zip(paths, files):
+                    if f.get_path() is None:
+                        raise ValueError(_("invalid path or URI \"%s\"") % p)
                 tab = self.open_files(
                     files, auto_compare=options.auto_compare,
                     auto_merge=auto_merge, new_tab=options.newtab,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]