aboutsummaryrefslogtreecommitdiff
path: root/src/bitcoinrpc.cpp
diff options
context:
space:
mode:
authorJeff Garzik <[email protected]>2012-04-15 16:47:24 -0400
committerJeff Garzik <[email protected]>2012-04-15 16:47:24 -0400
commitab9dc75a183c7a46e38e957ee3192d5febcccb3c (patch)
tree4af4074d5ef5859ce780af39f483cb02f5da5da2 /src/bitcoinrpc.cpp
parentMerge pull request #1104 from laanwj/2012_04_clang (diff)
downloaddiscoin-ab9dc75a183c7a46e38e957ee3192d5febcccb3c.tar.xz
discoin-ab9dc75a183c7a46e38e957ee3192d5febcccb3c.zip
The string class returns string::npos, when find() fails.
Noticed when sign-comparison warnings were enabled.
Diffstat (limited to 'src/bitcoinrpc.cpp')
-rw-r--r--src/bitcoinrpc.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bitcoinrpc.cpp b/src/bitcoinrpc.cpp
index 63c51ada8..f0d27fad9 100644
--- a/src/bitcoinrpc.cpp
+++ b/src/bitcoinrpc.cpp
@@ -201,7 +201,7 @@ Value help(const Array& params, bool fHelp)
// Help text is returned in an exception
string strHelp = string(e.what());
if (strCommand == "")
- if (strHelp.find('\n') != -1)
+ if (strHelp.find('\n') != string::npos)
strHelp = strHelp.substr(0, strHelp.find('\n'));
strRet += strHelp + "\n";
}