mirror of
https://git.wownero.com/wownero/wownero-puddle.git
synced 2024-08-15 01:03:20 +00:00
log failures of balance transfers
This commit is contained in:
parent
af9b9c8953
commit
6471c6a20a
1 changed files with 7 additions and 2 deletions
|
@ -1729,9 +1729,9 @@ rpc_on_wallet_transferred(const char* data, rpc_callback_t *callback)
|
|||
int ec = json_object_get_int(code);
|
||||
const char *em = json_object_get_string(message);
|
||||
log_error("Error (%d) with wallet transfer: %s", ec, em);
|
||||
goto cleanup;
|
||||
}
|
||||
log_info("Payout transfer successfull");
|
||||
else
|
||||
log_info("Payout transfer successfull");
|
||||
|
||||
int rc;
|
||||
char *err;
|
||||
|
@ -1772,6 +1772,11 @@ rpc_on_wallet_transferred(const char* data, rpc_callback_t *callback)
|
|||
}
|
||||
uint64_t current_amount = *(uint64_t*)val.mv_data;
|
||||
current_amount -= payment->amount;
|
||||
if (error)
|
||||
{
|
||||
log_warn("Error seen on transfer for %s with amount %"PRIu64,
|
||||
payment->address, payment->amount);
|
||||
}
|
||||
MDB_val new_val = {sizeof(current_amount), (void*)¤t_amount};
|
||||
rc = mdb_cursor_put(cursor, &key, &new_val, MDB_CURRENT);
|
||||
if (rc != 0)
|
||||
|
|
Loading…
Reference in a new issue