Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes issue with wrong assumption about binary protocol #56

Closed
wants to merge 1 commit into from
Closed

fixes issue with wrong assumption about binary protocol #56

wants to merge 1 commit into from

Conversation

elmacnifico
Copy link
Contributor

the original implementation thought that "size" would describe the
number of elements in the following array while it in fact desribes the
number of bytes that will be in the following array. so any assumption
about the number of elements would be flawed and lead to too many
itterations ending in EOF reading errors

the original implementation thought that "size" would describe the
number of elements in the following array while it in fact desribes the
number of bytes that will be in the following array. so any assumption
about the number of elements would be flawed and lead to too many
itterations ending in EOF reading errors
@elmacnifico
Copy link
Contributor Author

sorry i wanted to pull this into our fork for some refactoring first. but the general problem should be clear ;). so ignore this one if you like, as i may find a more elegant solution.

@elmacnifico
Copy link
Contributor Author

also the decoding of header tables with nested field-arrays should be tested

@wellle
Copy link

wellle commented Apr 5, 2013

In order to reproduce the behavior in question you can use the following small go program. (instructions included)
https://gist.github.com/wellle/5319271

@streadway
Copy link
Owner

Thanks for the report. The spec is ambiguous about the interpretation of the size field in array packing so I'll also be digging through other client implementations and get some better tests in over the weekend. I plan on using http://golang.org/pkg/io/#LimitedReader in the final implementation.

@streadway streadway closed this in 8d16fb0 Apr 7, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants