[General] Safari 4 Crashing: A Patch

Philip Weaver philmaker at gmail.com
Thu Apr 9 13:15:09 CEST 2009


Actually it might be more cautious to just add special case in
computeExtents (html). But I'm sure you all can figure out what's best.
Phil

On Thu, Apr 9, 2009 at 6:00 AM, Philip Weaver <philmaker at gmail.com> wrote:

>
> The crash is related to the value returned from String.fromCharCode(173).
> In Lively and in a simple html file: console.log prints nothing visible for
> the character and window.alert prints a character. This displayed character
> resembles a minus symbol. I haven't found an ascii table yet which indicates
> what this is supposed to represent.
>
> Tracked this down via computeExtents[Config.fontMetricsFromHTML] in
> Text.js. I attempted to do some detections on the text node and try/catch
> but was unsuccessful. Have not reported anything to Apple - feel free.
>
> String.fromCharCode = String.fromCharCode.wrap(function(proceed, charCode)
> {
> var result = proceed(charCode);
> if (charCode == 173) {
>  result = '-';
> }
> return result;
> });
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://livelykernel.sunlabs.com/pipermail/general/attachments/20090409/e1fa56b4/attachment.html 




More information about the lively-kernel mailing list