Version: (using Devel) Compiler: gcc 4.4 OS: Linux Installed from: Compiled sources When built with gcc 4.4 without -fno-strict-aliasing, kjs crashes as soon as any javascript code is being executed. The problem turns out to be aliasing violations in dtoa.cpp, which looks like it has at some point been forked off nspr -- nspr has already come up with a fix (see https://bugzilla.mozilla.org/show_bug.cgi?id=439144). I've ported their fix to kjs (will attach) -- I've been running it here for a few hours without noticing any weird stuff.
Created attachment 32873 [details] Fix
Created attachment 32874 [details] Cleanup patch Looking at the file, there's some odd stuff going on outside the aliasing violations -- in C++ code, it doesn't really make sense to support K&R constructs. Attaching another patch which gets rid of those (to be applied on top of the previous one), but this one isn't required to fix the problem.
I tried the patch and I can confirm that kjs does not crash any more after this patch.
SVN commit 960321 by bero: Fix crash when built with gcc 4.4 without -fno-strict-aliasing Details included in the bug report. BUG:189809 M +26 -147 dtoa.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=960321
SVN commit 960767 by kkofler: Fix crash when built with gcc 4.4 without -fno-strict-aliasing Details included in the bug report. CCBUG:189809 (backport revision 960321 by bero from trunk) M +26 -147 dtoa.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=960767