This PR enables DNS blocklist, and forces it on. This is meant to be a temporary solution to the massive number of outdated nodes. Once the network has stabilized again, DNS blocklist should be disabled by default again.
Co-authored-by: _xxfedexx_ <>
Reviewed-on: https://git.wownero.com/wownero/wownero/pulls/476
Co-authored-by: _XxFedexX_ <_xxfedexx_@noreply.gitgud.wownero.nl>
Co-committed-by: _XxFedexX_ <_xxfedexx_@noreply.gitgud.wownero.nl>
It's not allowed to use WaitForSingleObject with _beginthread, because the thread closes its own handle before exiting.
So the wait function will either wait on an invalid handle, or on a different handle used by something else.
Or, if it starts waiting before the thread exits, the behavior is undefined according to MS: "If this handle is closed while the wait is still pending, the function's behavior is undefined."
In my test sync I observed threads getting stuck infinitely on WaitForSingleObject, and then rx_set_main_seedhash spamming new threads when RandomX seed changes again. Eventually the system ran out of resources, and monerod aborted with "Couldn't start RandomX seed thread" message.
This PR fixes it by using `_beginthreadex` instead and explicitly closing the handle when it's safe.
For privacy reasons, time functions use GMT, to avoid logs leaking
timezones. It'd make more sense to use localtime for wallet output
(which are not logged by default), but that adds inconsistencies
which can also be confusing. So add a Z suffix for now to make it
clear these are not local time.
- Add interface for bytes sent/received
- Allow wallet refresh while daemon is not synchronized
- emit success boolean for refreshed()
- don't call refreshThreadFunc (we don't need it)
- lower rpc timeout from 3m30s (?!) to 10 seconds