Skip to content

bdecode variant without erroring on long string? #5

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

Closed
itdaniher opened this issue Apr 5, 2017 · 1 comment
Closed

bdecode variant without erroring on long string? #5

itdaniher opened this issue Apr 5, 2017 · 1 comment

Comments

@itdaniher
Copy link
Contributor

Doing some hacking on @boramalper's magnetico.

It relies on data present at the end of a bencoded bytestring. In order to use bencoder.pyx I had to patch out https://github.com/whtsky/bencoder.pyx/blob/master/bencoder.pyx#L96 and return both r and l.

See https://github.com/boramalper/magnetico/blob/master/magneticod/magneticod/bencode.py#L53 for the function for which I needed to add a replacement.

Would this project accept a PR adding a bdecode2 returning both r and l, and not erroring on excess data?

Thanks!

@whtsky
Copy link
Owner

whtsky commented Apr 6, 2017

Yes.

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

No branches or pull requests

2 participants