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

first element being a zero length string (REDUX) #1056

Closed
AlbeSure opened this issue Apr 29, 2015 · 6 comments
Closed

first element being a zero length string (REDUX) #1056

AlbeSure opened this issue Apr 29, 2015 · 6 comments

Comments

@AlbeSure
Copy link

Referencing #896 and #983
Quick disclaimer: I am NOT a programmer (NOT even close)...

With that being said, the reason for my post here is an effort to get some MORE information about Novik's response here (in #983):

This is, of course, a ruTorrent error (i.e. an error in the PHP class of Adrien), but it can't be fixed by such way, and yes, function encode_string still unchanged.
Function folder was corrected (5 month ago), and, IMHO, this should fix this error.

So, the thing that I am not quite clear on is...has the "first element being a zero length string" found in newly created .torrent files been FULLY resolved in a release version of ruTorrent (and, if so...beginning in which version)?

Thank you so much!

-A.S.

@hwkns
Copy link

hwkns commented Apr 30, 2015

I'll chime in with what I've found researching this so far:

Zero-length strings can be used as valid values in a dictionary, so that's why the patch to prevent the encode_string function from bencoding zero-length strings was rejected. We need a solution that is specific to the path component list to properly resolve this issue.

@Novik when you said "folder was corrected (5 month ago)" were you referring to this change? b816160#diff-aad3f03edf239a1253a1c07d48344310R516 Could anyone more PHP-skilled than me point out why that change might have fixed it?

You can clone the repo to get the most up-to-date code, but it looks like the last official release of ruTorrent was 3.6, in October of 2013: https://github.com/Novik/ruTorrent/releases/tag/rutorrent

@JohnFlowerful
Copy link

The key change is this:

$len = strlen( $string );
return($len ? $len . ':' . $string : '');

In layman's terms, if the string's length is true (i.e. greater than 0) then return $len:$string, else return an empty string.

I would consider git HEAD to be stable for everyday use. The 'official release' should link to the zip of master branch.

@Novik
Copy link
Owner

Novik commented Apr 30, 2015

The key change is this

These changes are incorrect and was reverted.

but it looks like the last official release of ruTorrent was 3.6

The last official release of ruTorrent is 3.7.

@hwkns
Copy link

hwkns commented Apr 30, 2015

The last official release of ruTorrent is 3.7.

@Novik where can I find that release, and does it include the fix to the folder function, and does that fix fully resolve the null path component issue?

@Novik
Copy link
Owner

Novik commented Apr 30, 2015

where can I find that release

Try to see to the front page of project.

and does it include the fix to the folder function, and does that fix fully resolve the null path component issue?

Try to check.

@hwkns
Copy link

hwkns commented Apr 30, 2015

Thanks for all your help. -_-

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

4 participants