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

Fix incorrect content length for the instrumented source #51

Merged
merged 1 commit into from Apr 12, 2013
Merged

Fix incorrect content length for the instrumented source #51

merged 1 commit into from Apr 12, 2013

Conversation

dkubb
Copy link
Contributor

@dkubb dkubb commented Apr 11, 2013

The original code used String#length, which returns the length of the string in characters, but the header must be the length of the string in bytes. This was causing errors because the browser was (presumably) truncating the content after receiving a (lower) specific number of bytes than the actual number of bytes in the content.

* The original code  used String#length, which returns the length
  of the string in characters, but the header must be the length of
  the string in bytes. This was causing errors because the browser
  was (presumably) truncating the content after receiving a (lower)
  specific number of bytes than the actual number of bytes in the
  content.
@dkubb
Copy link
Contributor Author

dkubb commented Apr 11, 2013

Hmm, travis seems to be reporting an error unrelated to my change. I see in #50 there are attempts to fix it too, so I won't duplicate that effort unless it gets blocked.

@jejacks0n
Copy link
Owner

Cheers! Thanks for this fix, I learned something new. =)

jejacks0n added a commit that referenced this pull request Apr 12, 2013
Fix incorrect content length for the instrumented source
@jejacks0n jejacks0n merged commit 99d8451 into jejacks0n:master Apr 12, 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

2 participants