RESOLVED FIXED 7884
REGRESSION: Selecting a custom style sheet crashes 20/3 nightly
https://bugs.webkit.org/show_bug.cgi?id=7884
Summary REGRESSION: Selecting a custom style sheet crashes 20/3 nightly
musti
Reported 2006-03-20 21:42:54 PST
Steps to reproduce when WebKit nightly is open and NO custom style sheet is selected via Safari beforehand: 1. Select a custom style sheet in Preferences --> Advanced --> Style Sheet 2. reload the current page Steps to reproduce when a custom style sheet is selected via Safari before launching WebKit nightly 1. Launch WebKit nightly. 2. Crashes upon launch, even when trying to load the WebKit start page. Part of crash log Exception: EXC_BAD_ACCESS (0x0001) Codes: KERN_INVALID_ADDRESS (0x0001) at 0xbf7fffdc Thread 0 Crashed: 0 com.apple.JavaScriptCore 0x001763a8 KXMLCore::fastMalloc(unsigned long) + 8 1 com.apple.WebCore 0x01367b50 KXMLCore::Vector<char, (unsigned long)4096>::reserveCapacity(unsigned long) + 64 2 com.apple.WebCore 0x01367c04 KXMLCore::Vector<char, (unsigned long)4096>::expandCapacity(unsigned long) + 84 3 com.apple.WebCore 0x01367c54 KXMLCore::Vector<char, (unsigned long)4096>::resize(unsigned long) + 52 4 com.apple.WebCore 0x012be808 KURL::parse(char const*, DeprecatedString const*) + 1176 5 com.apple.WebCore 0x012c0584 KURL::KURL[in-charge](KURL const&, DeprecatedString const&, WebCore::TextEncoding const&) + 1860 6 com.apple.WebCore 0x011608fc WebCore::Document::completeURL(DeprecatedString const&) + 428 7 com.apple.WebCore 0x011807c0 WebCore::Cache::requestStyleSheet(WebCore::DocLoader*, WebCore::String const&, bool, long, DeprecatedString const&) + 112 8 com.apple.WebCore 0x0113b7d4 WebCore::Frame::setUserStyleSheet(KURL const&) + 260 9 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet(WebCore::String const&, WebCore::String const&) + 52 10 com.apple.WebCore 0x0113b7fc WebCore::Frame::setUserStyleSheet(KURL const&) + 300 11 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet(WebCore::String const&, WebCore::String const&) + 52 12 com.apple.WebCore 0x0113b7fc WebCore::Frame::setUserStyleSheet(KURL const&) + 300 13 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet(WebCore::String const&, WebCore::String const&) + 52 14 com.apple.WebCore 0x0113b7fc WebCore::Frame::setUserStyleSheet(KURL const&) + 300 15 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet(WebCore::String const&, WebCore::String const&) + 52 16 com.apple.WebCore 0x0113b7fc WebCore::Frame::setUserStyleSheet(KURL const&) + 300 17 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet snip snip snip 507 com.apple.WebCore 0x01348814 WebCore::UserStyleSheetLoader::setStyleSheet(WebCore::String const&, WebCore::String const&) + 52 508 com.apple.WebCore 0x0113b7fc WebCore::Frame::setUserStyleSheet(KURL const&) + 300
Attachments
Patch (1.20 KB, patch)
2006-03-21 12:41 PST, mitz
darin: review+
Rename the function that sets the location (2.70 KB, patch)
2006-03-21 13:54 PST, mitz
darin: review+
Chris Petersen
Comment 1 2006-03-20 23:24:57 PST
I ran into this issue starting with the March 21 build (WebKit-SVN-r13404). You can reproduce by simply applying any external stylesheet to Safari (even a empty stylesheet file) when running Webkit WebKit-SVN-r13404.
Alice Liu
Comment 2 2006-03-21 09:21:45 PST
mitz
Comment 3 2006-03-21 12:12:10 PST
When I have this page open and I change the user style sheet, Safari tries to load the URL http://bugzilla.opendarwin.org/<contents of the style sheet I selected>. When that fails, it starts loading http://bugzilla.opendarwin.org/<contents of the error page from the previous attempt> and when that fails, it repeats.
mitz
Comment 4 2006-03-21 12:41:52 PST
mitz
Comment 5 2006-03-21 13:19:59 PST
Comment on attachment 7220 [details] Patch Better just rename one of the functions.
Darin Adler
Comment 6 2006-03-21 13:41:36 PST
Comment on attachment 7220 [details] Patch It would be even better to rename the one that takes a URL to setStyleSheetLocation, but this is good.
mitz
Comment 7 2006-03-21 13:54:14 PST
Created attachment 7221 [details] Rename the function that sets the location
Darin Adler
Comment 8 2006-03-21 14:47:53 PST
Comment on attachment 7221 [details] Rename the function that sets the location Great, lets do this.
Eric Seidel (no email)
Comment 9 2006-03-22 01:13:47 PST
Sorry about this. I noticed it last night, but didn't get a fix ready in time. :( I actually had made the exact same fix locally.
Note You need to log in before you can comment on or make changes to this bug.