private synchronized void resetClient() { client = null; try { service.removeAccount(listener); service.registerAccount( prefs.getString("user", ""), prefs.getString("password", ""), listener); } catch (Throwable t) { Log.e("Patchy", "Exception in resetClient()", t); goBlooey(t); } }
@Override public void onDestroy() { super.onDestroy(); locMgr.removeUpdates(onLocationChange); try { if (service != null) { service.removeAccount(listener); } } catch (Throwable t) { Log.e("Patchy", "Exception in call to removeAccount()", t); goBlooey(t); } unbindService(svcConn); }