Browse Source

daemon: default rpc socktype to "tcp" if `rpcport` is set

Having `rpcport` set already indicates the user does not want unix sockets,
we just default `rpchost` to "localhost".

related https://github.com/spesmilo/electrum/issues/7811
patch-4
SomberNight 3 years ago
parent
commit
641c3e23a4
No known key found for this signature in database GPG Key ID: B33B5F232C6271E9
  1. 2
      electrum/daemon.py

2
electrum/daemon.py

@ -67,7 +67,7 @@ def get_rpcsock_defaultpath(config: SimpleConfig):
return os.path.join(config.path, 'daemon_rpc_socket')
def get_rpcsock_default_type(config: SimpleConfig):
if config.get('rpchost') and config.get('rpcport'):
if config.get('rpcport'):
return 'tcp'
# Use unix domain sockets when available,
# with the extra paranoia that in case windows "implements" them,

Loading…
Cancel
Save