Context's currentPath should check for passed type
https://bugs.webkit.org/show_bug.cgi?id=109097

Patch by Dirk Schulze <dschulze@adobe.com> on 2013-02-06
Reviewed by Dean Jackson.

Source/WebCore:

Add check for passed pointer and return earlier.

Test: fast/canvas/canvas-currentPath-crash.html

* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::setCurrentPath):

LayoutTests:

Add checks with different data types as value for canvas.currentPath.

* fast/canvas/canvas-currentPath-crash-expected.txt: Added.
* fast/canvas/canvas-currentPath-crash.html: Added.
* fast/canvas/script-tests/canvas-currentPath-crash.js: Added.
* platform/chromium/TestExpectations:
* platform/efl/TestExpectations:
* platform/gtk/TestExpectations:
* platform/mac/TestExpectations:
* platform/qt/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@142051 268f45cc-cd09-0410-ab3c-d52691b4dbfc