Commit Graph

31710 Commits

Author SHA1 Message Date
Duke
5a3c06e539 MAX_BLOCK_SIZE ignores height argument
The function no longer looks at this argument so don't waste resources calculating a height.
2024-09-20 11:18:16 -04:00
Duke
ad8a86a19b Merge branch 'dev' into duke 2024-09-18 12:16:29 -04:00
Duke
d471af9ef5 IsPegsImport() is always false
Since this function always returns false and is used in many "hot"
code paths, removing it from the code should give us a performance boost.
2024-09-18 12:13:37 -04:00
Duke
ffce5edda3 Remove commented out code 2024-09-18 11:59:00 -04:00
Duke
5e30079fcd IsPegsImport() always returns false 2024-09-18 11:53:40 -04:00
Duke
160802cddf Update relnotes 2024-09-18 11:48:52 -04:00
Duke
fcc5c17628 Bump protocol version and client version 2024-09-18 10:59:37 -04:00
Duke
d915fc38b7 Add some useful comments to the wolfssl package 2024-09-18 10:53:28 -04:00
Duke
adbd47980c Merge branch 'dev' of https://git.hush.is/hush/hush3 into dev 2024-09-18 10:50:42 -04:00
duke
c567096aae Merge pull request 'wolfssl downgrade to 4.8.1' (#422) from wolfssldowngrade into dev
Reviewed-on: https://git.hush.is/hush/hush3/pulls/422
2024-09-18 16:48:29 +02:00
Duke
27f72405b2 Also print address to stderr in hush_isnotaryvout 2024-09-17 13:11:11 -04:00
Duke
bd967b7ac6 Exit out of TLSManager::waitFor() loop if shutdown requested 2024-09-17 11:30:01 -04:00
Duke
8adaa3641f Exit out of TLSManager::waitFor() loop if shutdown requested 2024-09-17 11:29:24 -04:00
onryo
6feea4cfd2 wolfssl downgrade to 4.8.1 test 2024-09-17 09:25:58 +00:00
duke
49f303d804 Merge pull request 'Sync duke branch to dev' (#420) from duke into dev
Reviewed-on: https://git.hush.is/hush/hush3/pulls/420
2024-09-16 17:31:37 +02:00
Duke
3f50dd988a Only use -rdynamic on debug builds 2024-09-16 11:26:28 -04:00
Duke
bc20629b9f Revert "Fix memory DoS"
This reverts commit 84377caae7.
2024-09-16 11:18:16 -04:00
Duke
fc5b0f38bd Revert "Memory DoS fixes"
This reverts commit 6a5f0eafde.
2024-09-16 11:17:56 -04:00
Duke
c5eeb74807 Simplify MAX_BLOCK_SIZE
Our code requires sapling activation at height 1 so we can simplify this function
which should lead to some performance improvements since it is called from many
places, including mining code.
2024-09-16 11:06:31 -04:00
fekt
6a5f0eafde Memory DoS fixes 2024-09-15 01:20:06 -04:00
Duke
912942f2a8 Delete more CC stuff 2024-09-13 18:50:28 -04:00
Duke
4f4a72da8e Go back to taking both main+wallet lock in DecrementWitnesses
By taking a wallet lock first and then main later we run into
a potential deadlock :

2024-09-13 11:14:37 POTENTIAL DEADLOCK DETECTED
2024-09-13 11:14:37 Previous lock order was:
2024-09-13 11:14:37  (1) cs_wallet  wallet/wallet.cpp:985
2024-09-13 11:14:37  (2) cs_main  wallet/wallet.cpp:890
2024-09-13 11:14:37 Current lock order is:
2024-09-13 11:14:37  (2) cs_main  wallet/wallet.cpp:2845
2024-09-13 11:14:37  (1) cs_wallet  wallet/wallet.cpp:2845
2024-09-13 09:34:10 -04:00
Duke
f5cae3b403 getinfo rpc needs a cs_wallet lock
Without it we get an AssertLockHeld when calling GetKeyPoolSize .
We could probably make this lock apply to less code, possibly only
the single line that calls GetKeyPoolSize() needs it.
2024-09-13 04:37:48 -04:00
Duke
6845fcd93a This rpc can only be used on non z2z chains 2024-09-13 04:22:28 -04:00
Duke
be3641158a Only take cs_main lock in GetSaplingSpendDepth
We do not seem to need this lock for the entire DecrementNoteWitnesses function,
we need it only when calling GetSaplingSpendDepth. Also protects against
the case in the future where some code without cs_main calls GetSaplingSpendDepth.
2024-09-13 04:11:38 -04:00
Duke
72c530d281 SMART_CHAIN_SYMBOL is always defined 2024-09-13 03:50:07 -04:00
fekt
84377caae7 Fix memory DoS 2024-09-13 04:22:08 +00:00
Duke
7e486538c9 SMART_CHAIN_SYMBOL is always set, so we can remove these checks 2024-09-12 20:12:26 -04:00
Duke
215d0b7db4 Remove commented out code 2024-09-12 20:02:10 -04:00
Duke
8b0c0493ac Ensure cs_main lock is held when TestBlockValidity() is called 2024-09-12 19:47:42 -04:00
Duke
04165e161a Explain more details about the burn address 2024-09-12 13:40:30 -04:00
onryo
d3cfecc425 Revert "Add burn address to the notary list"
This reverts commit 4fcb3e6ed5.
2024-09-12 19:28:30 +02:00
onryo
25dc60e6b5 Revert "Add season 8"
This reverts commit e104a33f2a.
2024-09-12 19:26:51 +02:00
Duke
f8e7df37a1 Delete commented out code 2024-09-12 12:12:59 -04:00
Duke
7f9878cf0c Take a lock on cs_main in DecrementNoteWitnesses
Another possibly better approach would be to take a lock inside
GetSaplingSpendDepth since we want the lock to apply to as little
code as possible and it is GetSaplingSpendDepth that calls GetDepthInMainChain
which requires a cs_main lock .
2024-09-12 11:47:58 -04:00
onryo
e104a33f2a Add season 8 2024-09-12 17:42:42 +02:00
Duke
aab240e3b3 Temporary change to add -rdynamic to build flags
This allows us to see function names in a backtrace when AssertLockHeld
gives us an assert, which is helping to debug our deadlock bug.

This code should be improved to only do this for debug builds.
2024-09-12 11:21:46 -04:00
onryo
4fcb3e6ed5 Add burn address to the notary list
This change allows sending funds to the burn address.
2024-09-12 16:21:29 +02:00
onryo
243c726243 Update checkpoints for Hush and DragonX 2024-09-12 15:38:57 +02:00
onryo
c9470f29b7 Update checkpoints for Hush and DragonX 2024-09-12 15:19:01 +02:00
Duke
ed86f2dd1d Sleep for 200us before each ActivateBestChainStep call
This should lower the main thread's likelihood to immediately reacquire
cs_main after dropping it, which should help ThreadNotifyWallets and the
RPC methods to acquire cs_main more quickly.

Ported from ZEC commit e2cd1b761fe556bc6d61849346902c3611530307
2024-09-12 00:21:56 -04:00
Duke
b4e083ae56 Add what seems to be missing locks in mining code 2024-09-11 23:59:57 -04:00
Duke
b71d95bdd4 Delete disabled code 2024-09-11 23:32:46 -04:00
Duke
aa75877cd6 Print stacktrace when asserting a lock is held 2024-09-11 23:31:44 -04:00
Duke
726191cad4 Merge branch 'dev' into duke 2024-09-11 22:27:33 -04:00
Duke
2a910549ba Merge branch 'dev' of https://git.hush.is/hush/hush3 into dev 2024-09-11 14:53:58 -04:00
Duke
25f2ccb30e Document exactly what the RD6GgnrMpPaTSMn8vai6yiGA7mN4QGPVMY address is and how it is derived 2024-09-11 14:53:33 -04:00
duke
1965ad23c9 Merge pull request 'Sync duke to dev' (#415) from duke into dev
Reviewed-on: https://git.hush.is/hush/hush3/pulls/415
2024-08-11 19:01:17 +02:00
Duke
1e892f23e6 Remove dead nVersion code
This is very old code from the early days of Bitcoin, our mainnets have
never used peer protocol version.

Originally 150ab1d34c
2024-08-07 07:18:08 -07:00
Duke
7f27489224 Speed up compile by disabling libevent sample code, originally f38c051048 2024-08-07 07:11:13 -07:00