diff options
| author | Wladimir J. van der Laan <[email protected]> | 2016-11-03 19:18:22 +0100 |
|---|---|---|
| committer | Wladimir J. van der Laan <[email protected]> | 2016-11-03 19:20:01 +0100 |
| commit | 82077ef6e49a08b3772d5c82f6e0cfe390e11966 (patch) | |
| tree | a5567b3cc550d05c5bd45d8c6dc6258bff7ca9ee /src/bitcoin-cli.cpp | |
| parent | Merge #8969: Decouple peer-processing-logic from block-connection-logic (#2) (diff) | |
| parent | Add common failure cases for rpc server connection failure (diff) | |
| download | discoin-82077ef6e49a08b3772d5c82f6e0cfe390e11966.tar.xz discoin-82077ef6e49a08b3772d5c82f6e0cfe390e11966.zip | |
Merge #9073: Trivial: Add common failure cases for rpc server connection failure
8f329f9 Add common failure cases for rpc server connection failure (instagibbs)
Diffstat (limited to 'src/bitcoin-cli.cpp')
| -rw-r--r-- | src/bitcoin-cli.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bitcoin-cli.cpp b/src/bitcoin-cli.cpp index 2d66448d8..8a2f380e6 100644 --- a/src/bitcoin-cli.cpp +++ b/src/bitcoin-cli.cpp @@ -240,7 +240,7 @@ UniValue CallRPC(const string& strMethod, const UniValue& params) event_base_free(base); if (response.status == 0) - throw CConnectionFailed(strprintf("couldn't connect to server (%d %s)", response.error, http_errorstring(response.error))); + throw CConnectionFailed(strprintf("couldn't connect to server\n(make sure server is running and you are connecting to the correct RPC port: %d %s)", response.error, http_errorstring(response.error))); else if (response.status == HTTP_UNAUTHORIZED) throw runtime_error("incorrect rpcuser or rpcpassword (authorization failed)"); else if (response.status >= 400 && response.status != HTTP_BAD_REQUEST && response.status != HTTP_NOT_FOUND && response.status != HTTP_INTERNAL_SERVER_ERROR) |