[kupfer: 20/51] main: Fix output of getopt error



commit b6949f9c61f0213c446d81674e2bf51b8409b7b0
Author: Ulrik Sverdrup <ulrik sverdrup gmail com>
Date:   Mon Mar 28 16:51:44 2011 +0200

    main: Fix output of getopt error

 kupfer/main.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/kupfer/main.py b/kupfer/main.py
index a3fcf3e..7a21a42 100644
--- a/kupfer/main.py
+++ b/kupfer/main.py
@@ -75,8 +75,8 @@ def get_options():
 		opts, args = getopt.getopt(sys.argv[1:], "",
 				[o for o,h in program_options] +
 				[o for o,h in misc_options])
-	except getopt.GetoptError, info:
-		prt(info)
+	except getopt.GetoptError as exc:
+		prt(unicode(exc))
 		prt(make_help_text())
 		raise SystemExit
 



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