Tiny refactor of IsRBFOptIn, avoid exception#7812
Merged
laanwj merged 1 commit intobitcoin:masterfrom Apr 14, 2016
Merged
Conversation
Member
|
Concept ACK |
Member
|
Looks good, thanks for cleaning this up. This code is tested in |
Contributor
Author
There was a problem hiding this comment.
Meh. Had that first, but the if/elseif uses less lines (just two conditions).
Contributor
There was a problem hiding this comment.
In this case, I think '?' operator is the best solution here... Isn't FINAL case missing here anyway?
Contributor
Author
There was a problem hiding this comment.
I think the ? operator does not fit well for a non-boolean. The FINAL case is handled by the default value set at L82.
Contributor
|
Commit message typo: expection -> exception |
Contributor
|
utACK 1e211e2 |
1e211e2 to
4f7c959
Compare
Contributor
Author
|
Force push fixed the git commit message typo. |
Member
|
utACK 4f7c959 |
1 similar comment
Member
|
utACK 4f7c959 |
laanwj
added a commit
that referenced
this pull request
Apr 14, 2016
4f7c959 Refactor IsRBFOptIn, avoid exception (Jonas Schnelli)
codablock
pushed a commit
to codablock/dash
that referenced
this pull request
Dec 20, 2017
4f7c959 Refactor IsRBFOptIn, avoid exception (Jonas Schnelli)
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
While working with RBF in the GUI, the exception in
IsRBFOptIn()(throw std::runtime_error("Cannot determine RBF opt-in signal for non-mempool transaction\n")) could be unexpected.