Avoid heap usage when encoding to base58#191
Merged
apoelstra merged 2 commits intorust-bitcoin:masterfrom Dec 4, 2018
Merged
Conversation
sgeisler
commented
Nov 9, 2018
src/util/base58.rs
Outdated
Contributor
Author
There was a problem hiding this comment.
It is obvious to me that the function should be renamed since it'f no longer returning UTF-8 bytes but rather writing unicode chars to a writer. What would you think is a good name instead?
sgeisler
commented
Nov 10, 2018
sgeisler
commented
Dec 3, 2018
src/util/base58.rs
Outdated
Contributor
Author
There was a problem hiding this comment.
I just noticed that this function becomes redundant.
Member
|
Looks great, thanks! |
apoelstra
approved these changes
Dec 4, 2018
yancyribbens
pushed a commit
to yancyribbens/rust-bitcoin
that referenced
this pull request
Mar 23, 2024
…straints
overhaul interpreter ("satisfied constraints") API
PastaPastaPasta
pushed a commit
to PastaPastaPasta/rust-dashcore
that referenced
this pull request
Feb 2, 2026
rust-bitcoin#190 removed the read timeouts of the `Peer::receive_message` which currently leads to a lockup of the peer because the write lock is held while waiting for the message. Needs some more refactoring but this works for now.
PastaPastaPasta
pushed a commit
to PastaPastaPasta/rust-dashcore
that referenced
this pull request
Feb 2, 2026
The sleep timeout branch introduced in rust-bitcoin#191 returns an `Err(NetworkError::Timeout)` which leads to a misbehavior update below in the `msg_result` match and eventually in a peer ban. This shouldn't happen because the `sleep` timing out only means that there is no data available right now. Instead, it now returns `Ok(None)` which will just keep things going.
PastaPastaPasta
pushed a commit
to PastaPastaPasta/rust-dashcore
that referenced
this pull request
Feb 2, 2026
…-bitcoin#197) * feat(spv): flush headers on shutdown * move fn lower in the impl * refactor: `MultiPeerNetworkManager` -> `PeerNetworkManager` (rust-bitcoin#184) * refactor: `MultiPeerNetworkManager` -> `PeerNetworkManager` * Fix formatting and apply review * feat: Update ffi headers (rust-bitcoin#183) * feat(spv): broadcast transaction (rust-bitcoin#180) * fix: Fix `PeerNetworkManager` cast in `broadcast_transaction` (rust-bitcoin#185) PR rust-bitcoin#180 used `MultiPeerNetworkManager`, this was renamed in rust-bitcoin#183 which was merged before rust-bitcoin#180 but after its CI run. * fix: Use non-blocking `TcpStream` in `dash-spv::network::TcpConnection` (rust-bitcoin#188) * refactor: Improve SPV shutdown handling with `CancellationToken` (rust-bitcoin#187) * refactor: `TcpConnection` -> `Peer` and `ConnectionPool` -> `PeerPool` (rust-bitcoin#190) * fix: Locking issue after rust-bitcoin#190 (rust-bitcoin#191) rust-bitcoin#190 removed the read timeouts of the `Peer::receive_message` which currently leads to a lockup of the peer because the write lock is held while waiting for the message. Needs some more refactoring but this works for now. * fix: More follow-up to rust-bitcoin#190 (rust-bitcoin#193) The sleep timeout branch introduced in rust-bitcoin#191 returns an `Err(NetworkError::Timeout)` which leads to a misbehavior update below in the `msg_result` match and eventually in a peer ban. This shouldn't happen because the `sleep` timing out only means that there is no data available right now. Instead, it now returns `Ok(None)` which will just keep things going. * flush after mn list sync too * move flush to after header sync instead of mnlist * fix --------- Co-authored-by: Kevin Rombach <35775977+xdustinface@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Instead of always allocating a
Vecthis implementation will work on the stack only as long as the output stays below 100 characters.Closes #145