You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* feat(ffi): add dash_spv_ffi_config_clear_peers to remove default peers
When creating an SPV config for regtest, a default peer at
127.0.0.1:19899 is added. This doesn't match dashmate's Docker
setup which maps Core P2P to different ports (e.g. 20001). FFI
consumers (iOS/Swift) couldn't clear these defaults before adding
their own peers, causing the SPV client to enter exclusive mode
with a dead peer alongside the intended one.
Adds dash_spv_ffi_config_clear_peers() so FFI consumers can remove
default peers before adding custom ones via add_peer.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* chore: regenerate FFI docs and apply fmt
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* test: add unit tests for dash_spv_ffi_config_clear_peers
Tests cover:
- clearing peers after adding multiple peers
- clearing an already-empty peer list succeeds
- null pointer returns NullPointer error code
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Removes all configured peers from the configuration This is useful when the caller wants to start with a clean slate before adding custom peers via `dash_spv_ffi_config_add_peer`. # Safety - `config` must be a valid pointer to an FFIClientConfig created by dash_spv_ffi_config_new/mainnet/testnet - The caller must ensure the config pointer remains valid for the duration of this call
213
+
214
+
**Safety:**
215
+
-`config` must be a valid pointer to an FFIClientConfig created by dash_spv_ffi_config_new/mainnet/testnet - The caller must ensure the config pointer remains valid for the duration of this call
0 commit comments