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

Unicode characters in Har break beacon service #5

Closed
shadybones opened this issue Mar 13, 2014 · 1 comment
Closed

Unicode characters in Har break beacon service #5

shadybones opened this issue Mar 13, 2014 · 1 comment

Comments

@shadybones
Copy link

HarUploader.prototype.start()
includes:
this.request.setRequestHeader("Content-Length", jsonString.length);

which when jsonString includes unicode characters (by that, I mean bom-containing characters), the jsonString.length != jsonString.byteLength.

This makes the header incorrect and my beacon service can't parse the Har string.

Fix: I recommend just not setting the "Content-Length" header manually. Removing that line fixed the problem for me.

@janodvarko
Copy link
Member

Thanks for the report!

Patch committed at:
12b810d

Honza

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