aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2017-02-08 12:53:57 +0200
committerRiccardo Spagni <ric@spagni.net>2017-02-08 12:53:57 +0200
commit99ee3fd17ea39122c3388a5c3024425548d04f4d (patch)
treebfca08e6f3b7cb70da2af1679911cb6d4c3034a6 /src
parentMerge pull request #1678 (diff)
parentWallet API: Catch error from tools::is_local_address (diff)
downloadmonero-99ee3fd17ea39122c3388a5c3024425548d04f4d.tar.xz
Merge pull request #1679
4efc926d Wallet API: Catch error from tools::is_local_address (Jaquee)
Diffstat (limited to '')
-rw-r--r--src/wallet/api/utils.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/wallet/api/utils.cpp b/src/wallet/api/utils.cpp
index 788d98f25..c369427b4 100644
--- a/src/wallet/api/utils.cpp
+++ b/src/wallet/api/utils.cpp
@@ -39,8 +39,13 @@ namespace Monero {
namespace Utils {
bool isAddressLocal(const std::string &address)
-{
- return tools::is_local_address(address);
+{
+ try {
+ return tools::is_local_address(address);
+ } catch (const std::exception &e) {
+ MERROR("error: " << e.what());
+ return false;
+ }
}
}