From ff5b6c4eab17f6e270bc1c33cda10645b2f57c4b Mon Sep 17 00:00:00 2001 From: Jimmy Kiselak Date: Wed, 9 Sep 2015 12:17:46 -0400 Subject: [PATCH] if lbrycrd server fails to launch, don't stop it at shutdown --- lbrynet/core/LBRYcrdWallet.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lbrynet/core/LBRYcrdWallet.py b/lbrynet/core/LBRYcrdWallet.py index e399828a3..30f7fa58a 100644 --- a/lbrynet/core/LBRYcrdWallet.py +++ b/lbrynet/core/LBRYcrdWallet.py @@ -405,9 +405,12 @@ class LBRYcrdWallet(object): @_catch_connection_error def _rpc_stop(self): - rpc_conn = self._get_rpc_conn() - rpc_conn.stop() - self.lbrycrdd.wait() + # check if our lbrycrdd is actually running, or if we connected to one that was already + # running and ours failed to start + if self.lbrycrdd.poll() is None: + rpc_conn = self._get_rpc_conn() + rpc_conn.stop() + self.lbrycrdd.wait() class LBRYcrdAddressRequester(object):