If you create a 1 dimensional (width==0 || height==0) Pattern in Canvas, WebKit will crash.
Reproducible crash -> P1. Thread 0 Crashed: 0 com.apple.WebCore 0x0322d99d WTF::RefPtr<WebCore::Image>::operator!() const + 9 (RefPtr.h:63) 1 com.apple.WebCore 0x034aaa81 WebCore::ImageBuffer::image() const + 27 (ImageBufferCG.cpp:99) 2 com.apple.WebCore 0x032340f7 WebCore::CanvasRenderingContext2D::createPattern(WebCore::HTMLCanvasElement*, WebCore::String const&, int&) + 135 (CanvasRenderingContext2D.cpp:1154) 3 com.apple.WebCore 0x034f431d WebCore::JSCanvasRenderingContext2D::createPattern(KJS::ExecState*, KJS::ArgList const&) + 545 (JSCanvasRenderingContext2DCustom.cpp:328) 4 com.apple.WebCore 0x034eff04 WebCore::jsCanvasRenderingContext2DPrototypeFunctionCreatePattern(KJS::ExecState*, KJS::JSObject*, KJS::JSValue*, KJS::ArgList const&) + 96 (JSCanvasRenderingContext2D.cpp:780)
<rdar://problem/6163988>
Created attachment 23434 [details] Patch
Comment on attachment 23434 [details] Patch r=me
Committed revision 36442.