# Made by Arnaud Fontaine on 20070831 diff -x '*.pyc' -uNr pympd-0.07.old/src/modules/pympdclient2.py pympd-0.07/src/modules/pympdclient2.py --- pympd-0.07.old/src/modules/pympdclient2.py 2006-07-15 02:13:35.000000000 +0200 +++ pympd-0.07/src/modules/pympdclient2.py 2007-08-31 13:52:11.000000000 +0200 @@ -51,10 +51,9 @@ def _connect(self, mpd_host, mpd_port, mpd_password=None): try: self.mpd = mpdlib2.connect(host=mpd_host, port=mpd_port, password=mpd_password) - - return True - except: - return False + return "" + except Exception, msg: + return msg #updated # should work without adjustments. diff -x '*.pyc' -uNr pympd-0.07.old/src/modules/pympdriver.py pympd-0.07/src/modules/pympdriver.py --- pympd-0.07.old/src/modules/pympdriver.py 2006-07-15 02:13:35.000000000 +0200 +++ pympd-0.07/src/modules/pympdriver.py 2007-08-31 12:57:13.000000000 +0200 @@ -944,7 +944,8 @@ else: password = None - if self.pympd._connect(get('host'), int(get('port')), password): + err_msg = self.pympd._connect(get('host'), int(get('port')), password) + if not err_msg: self.statusLabel.set_text("Connected") self.connected = True self.correctConnectionButtons() @@ -956,7 +957,7 @@ self.hdStoreBuilt = False gobject.timeout_add(500, self.statusUpdate) else: - self.statusLabel.set_text("Connection Failed") + self.statusLabel.set_text("Connection Failed: %s" % err_msg) def correctConnectionButtons(self): if self.connected == True: