Bug 4554

Summary: run-webkit-test --svg crashes if build configuration == Development
Product: WebKit Reporter: Tobias Lidskog <tobiaslidskog>
Component: SVGAssignee: Eric Seidel (no email) <eric>
Status: RESOLVED FIXED    
Severity: Major    
Priority: P2    
Version: 420+   
Hardware: Mac   
OS: OS X 10.4   
Attachments:
Description Flags
Fix, adds FE_QUARTZ_CHECK_INPUT checks where necessary
none
svg that will crash even with fixes in previous diff
none
Added a few additional null checks eric: review+

Description Tobias Lidskog 2005-08-21 03:37:05 PDT
If WebCore+SVG is built with configuration Development the svg layout tests will crash. 

Thread 0 Crashed:
0   WebCore+SVG        	0x012af64c KWQReportBlockedException(KWQNSHandler&) + 108 
(KWQExceptions.mm:34)
1   WebCore+SVG        	0x015e70e0 KCanvasFEMergeQuartz::getCIFilter(KCanvasFilterQuartz*) const 
+ 632 (KCanvasFilterQuartz.mm:553)
2   WebCore+SVG        	0x015e5124 KCanvasFilterQuartz::getCIFilterStack(CIImage*) + 288 
(KCanvasFilterQuartz.mm:195)
...

The solution is to insert the following two lines in KCanvasFilterQuartz.mm, 
KCanvasFEMergeQuartz::getCIFilter:
FE_QUARTZ_CHECK_INPUT(inputImage);
FE_QUARTZ_CHECK_INPUT(previousOutput);
after [filter setDefaults];

I could upload a patch, but right now I have another change submitted for the same file (#4550).
Comment 1 Eric Seidel (no email) 2005-08-21 15:06:06 PDT
I have a patch for this already locally. 
Comment 2 Eric Seidel (no email) 2005-08-22 01:59:21 PDT
Created attachment 3506 [details]
Fix, adds FE_QUARTZ_CHECK_INPUT checks where necessary
Comment 3 Tobias Lidskog 2005-08-22 06:51:26 PDT
Created attachment 3514 [details]
svg that will crash even with fixes in previous diff

A few null checks are still missing, will upload updated patch
Comment 4 Tobias Lidskog 2005-08-22 06:52:59 PDT
Created attachment 3515 [details]
Added a few additional null checks

Added some additional null checks, the attached svg file won't crash with this
patch applied.
Comment 5 Eric Seidel (no email) 2005-08-22 11:47:52 PDT
Comment on attachment 3515 [details]
Added a few additional null checks

Looks good.