From 9c5c5bab8004e26469b751bf3477d7fd5ec61532 Mon Sep 17 00:00:00 2001 From: mjs Date: Thu, 5 May 2005 00:29:30 +0000 Subject: [PATCH] Reviewed by Darin. Crash in JavaScriptCore with RSS Visualizer * kjs/internal.cpp: (InterpreterImp::mark): mark staticNaN, it is usually protected by the Number prototype but there is a small window where it can get collected. git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9115 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- JavaScriptCore/ChangeLog | 10 ++++++++++ JavaScriptCore/kjs/internal.cpp | 2 ++ 2 files changed, 12 insertions(+) diff --git a/JavaScriptCore/ChangeLog b/JavaScriptCore/ChangeLog index 71d38e644917..e65fe7e6cd87 100644 --- a/JavaScriptCore/ChangeLog +++ b/JavaScriptCore/ChangeLog @@ -1,3 +1,13 @@ +2005-05-04 Maciej Stachowiak + + Reviewed by Darin. + + Crash in JavaScriptCore with RSS Visualizer + + * kjs/internal.cpp: + (InterpreterImp::mark): mark staticNaN, it is usually protected by the Number + prototype but there is a small window where it can get collected. + 2005-05-04 Darin Adler Reviewed by Dave Hyatt. diff --git a/JavaScriptCore/kjs/internal.cpp b/JavaScriptCore/kjs/internal.cpp index 40477f751a04..12adc7786212 100644 --- a/JavaScriptCore/kjs/internal.cpp +++ b/JavaScriptCore/kjs/internal.cpp @@ -753,6 +753,8 @@ void InterpreterImp::mark() UndefinedImp::staticUndefined->mark(); if (NullImp::staticNull && !NullImp::staticNull->marked()) NullImp::staticNull->mark(); + if (NumberImp::staticNaN && !NumberImp::staticNaN->marked()) + NumberImp::staticNaN->mark(); if (BooleanImp::staticTrue && !BooleanImp::staticTrue->marked()) BooleanImp::staticTrue->mark(); if (BooleanImp::staticFalse && !BooleanImp::staticFalse->marked()) -- 2.36.0