fix traceback when EDITOR is not set in the env #118976 by Paul Varner
authorMike Frysinger <vapier@gentoo.org>
Sun, 15 Jan 2006 19:23:27 +0000 (19:23 -0000)
committerMike Frysinger <vapier@gentoo.org>
Sun, 15 Jan 2006 19:23:27 +0000 (19:23 -0000)
svn path=/main/trunk/; revision=2564

bin/dispatch-conf

index 0940927fc7412764faee2a942d2424d657743697..586b98759f8e4dfd96c2c5e3b49687c9e427caa7 100755 (executable)
@@ -204,6 +204,8 @@ class dispatch:
                     show_new_diff = 1
                     continue
                 elif c == 'e':
+                    if not os.environ.has_key('EDITOR'):
+                        os.environ['EDITOR']='nano'
                     os.system(os.environ['EDITOR'] + ' ' + newconf)
                     continue
                 elif c == 'z':