Remove size limit in RPC client, keep it in server#4640
Merged
laanwj merged 2 commits intobitcoin:masterfrom Aug 7, 2014
Merged
Remove size limit in RPC client, keep it in server#4640laanwj merged 2 commits intobitcoin:masterfrom
laanwj merged 2 commits intobitcoin:masterfrom
Conversation
Split up HTTPReply into HTTPReply and HTTPReplyHeader, so that the message data can be streamed directly. Also removes a c_str(), which would have prevented binary output with NUL characters in it.
The size limit makes a lot of sense for the server, as it never has to accept very large data. The client, however, can request arbitrary amounts of data with `listtransactions` on a large wallet. Fixes bitcoin#4604.
|
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/p4640_733177ebd3ecf3a03c2acb6b244c8b3d1b4a3981/ for binaries and test log. |
|
This pr indeed solves the issue I had at #4604 |
Contributor
|
Untested ACK, looks good. |
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.
The size limit makes a lot of sense for the server, as it never has to accept very large data and has to protect against malicious clients.
The client, however, can request arbitrary amounts of data (for example with
listtransactionson a large wallet). Having a strict size limit makes little sense.Fixes #4604.
The second commit contains a slight optimization that prevents a redundent copy and removes a needless c_str which would mess with binary data.