diff options
author | Beat Bolli <bbolli@ewanet.ch> | 2011-06-22 11:09:54 +0200 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2011-06-22 12:25:53 -0400 |
commit | 3fc3463a4907bd6c52e71d8b3a6709c09f01b030 (patch) | |
tree | f5ca71f2eef76741f3cc4015aa7294beb46d8ee4 | |
parent | 4b65b081aaa268a7b0b381288da33556908ca8fe (diff) | |
download | gpsd-3fc3463a4907bd6c52e71d8b3a6709c09f01b030.tar.gz |
gps.py: suppress the stack trace on exit
Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
-rwxr-xr-x | gps/gps.py | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -366,7 +366,10 @@ if __name__ == '__main__': session = gps(**opts) session.stream(WATCH_ENABLE|WATCH_NEWSTYLE) - for report in session: - print report + try: + for report in session: + print report + except KeyboardInterrupt: + print # gps.py ends here |