servo / rust-mozjs

DEPRECATED - moved to servo/mozjs instead.
Mozilla Public License 2.0
293 stars 117 forks source link

Error reporting strings are Latin1, not UTF-8. #208

Closed eefriedman closed 9 years ago

eefriedman commented 9 years ago

Because the best way to convert from a 16-bit encoding to an 8-bit encoding is obviously truncation.

Review on Reviewable

michaelwu commented 9 years ago

Have you tried using report->ucmessage?

eefriedman commented 9 years ago

Just tried it... it contains the exact same Latin1 string inflated to u16.

michaelwu commented 9 years ago

Hmm I expected it to be the other way around. For example, in http://mxr.mozilla.org/mozilla-central/source/js/src/jscntxt.cpp#650 , ucmessage is the original string before truncation to latin1.

eefriedman commented 9 years ago

Added commit to use ucmessage. You can test for yourself if you want.

eefriedman commented 9 years ago

Oops; not sure how I forgot it was in the standard library. Updated.

eefriedman commented 9 years ago

@michaelwu Ping.

michaelwu commented 9 years ago

@bors-servo r+

eefriedman commented 9 years ago

Nothing is happening here; do I need to file a bug against saltfs or something?

jdm commented 9 years ago

@bors-servo: r=michaelwu I had to re-synchronize homu's queue for rust-mozjs.

bors-servo commented 9 years ago

:pushpin: Commit 9c4a2ba has been approved by michaelwu

bors-servo commented 9 years ago

:hourglass: Testing commit 9c4a2ba with merge bba1b42...

bors-servo commented 9 years ago

:broken_heart: Test failed - travis

eefriedman commented 9 years ago

The build timed out during the Spidermonkey build. The configuration probably needs to be changed somehow.

jdm commented 9 years ago

@bors-servo: retry

bors-servo commented 9 years ago

:hourglass: Testing commit 9c4a2ba with merge 0aae51a...

bors-servo commented 9 years ago

:broken_heart: Test failed - travis

jdm commented 9 years ago

Bah, we're being bitten by libc here. #211 needs to merge first.

jdm commented 9 years ago

@bors-servo: retry

bors-servo commented 9 years ago

:hourglass: Testing commit 9c4a2ba with merge e2458c4...

bors-servo commented 9 years ago

:sunny: Test successful - travis