From: Huang Peng Date: Tue, 5 Aug 2008 23:13:20 +0000 (+0800) Subject: Exit when can not connect to ibus-daemon. X-Git-Tag: 0.1.0.20080810~62 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9a475c6a8d89a1ebe3ee5b6a01a19f1d4b4332c7;p=platform%2Fupstream%2Fibus.git Exit when can not connect to ibus-daemon. --- diff --git a/setup/main.py b/setup/main.py index 3522e1c..ba866d9 100644 --- a/setup/main.py +++ b/setup/main.py @@ -19,6 +19,7 @@ # Free Software Foundation, Inc., 59 Temple Place, Suite 330, # Boston, MA 02111-1307 USA +import sys from os import path import gtk import gobject @@ -53,9 +54,8 @@ class Setup(object): try: self.__bus = ibus.Bus() except: - import traceback - traceback.print_exc() - self.__bus = None + print >> sys.stderr, "Can not connect to ibus-daemon!" + sys.exit(1) glade_file = path.join(path.dirname(__file__), "./setup.glade") self.__xml = glade.XML(glade_file)