Bug 15979 - Console logs in a database callback lose line number information
Summary: Console logs in a database callback lose line number information
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: 528+ (Nightly build)
Hardware: All OS X 10.4
: P2 Normal
Assignee: Oliver Hunt
Depends on:
Reported: 2007-11-13 22:48 PST by Brady Eidson
Modified: 2010-04-05 09:09 PDT (History)
3 users (show)

See Also:

Fix exception handling in the many places it wasn't correct. (17.26 KB, patch)
2008-07-20 04:37 PDT, Oliver Hunt
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brady Eidson 2007-11-13 22:48:40 PST
See http://bugs.webkit.org/show_bug.cgi?id=15976 and the layout test in LayoutTests/storage/transaction_callback_exception_crash.html

When an exception is thrown from within a callback, there is no line number information in the console log.

Why not?
Comment 1 Oliver Hunt 2008-07-20 01:39:53 PDT
Okay, I have looked at this.  You don't get line/source information as you are throwing a primitive value which we cannot attach useful information to -- if you were to throw an object, everything should just work.

If that is the case then this is a duplicate of bug #18855

Comment 2 Oliver Hunt 2008-07-20 03:49:31 PDT
I am now actually working on this.  There was a wide spread of incorrect exception handling (in the sense that value conversion was bogus, and line numbers being lost).
Comment 3 Oliver Hunt 2008-07-20 04:37:04 PDT
Created attachment 22387 [details]
Fix exception handling in the many places it wasn't correct.
Comment 4 Alexey Proskuryakov 2008-07-20 05:42:03 PDT
See also: bug 17470, bug 18232, bug 18234.
Comment 5 Oliver Hunt 2008-07-20 05:44:15 PDT
Comment on attachment 22387 [details]
Fix exception handling in the many places it wasn't correct.

Mark reviewed, and requested a few changes. 
Committing to http://svn.webkit.org/repository/webkit/trunk ...
	M	LayoutTests/ChangeLog
	M	LayoutTests/fast/dom/NamedNodeMap-setNamedItem-crash-expected.txt
	A	LayoutTests/fast/js/exceptions-thrown-in-callbacks-expected.txt
	A	LayoutTests/fast/js/exceptions-thrown-in-callbacks.html
	M	LayoutTests/fast/xpath/nsresolver-exception-expected.txt
	M	LayoutTests/fast/xsl/transform-xhr-doc-expected.txt
	M	LayoutTests/http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write-expected.txt
	M	LayoutTests/http/tests/security/aboutBlank/xss-DENIED-navigate-opener-javascript-url-expected.txt
	M	LayoutTests/http/tests/security/aboutBlank/xss-DENIED-set-opener-expected.txt
	M	LayoutTests/platform/mac/fast/dynamic/015-expected.txt
	M	LayoutTests/platform/mac/fast/events/updateLayoutForHitTest-expected.txt
	M	LayoutTests/platform/mac/tables/mozilla_expected_failures/bugs/bug92868_1-expected.txt
	M	LayoutTests/platform/mac/tables/mozilla_expected_failures/dom/appendCells1-expected.txt
	M	LayoutTests/platform/mac/tables/mozilla_expected_failures/dom/appendCellsRebuild1-expected.txt
	M	LayoutTests/platform/mac/tables/mozilla_expected_failures/dom/insertTbodyExpand1-expected.txt
	M	LayoutTests/platform/mac/tables/mozilla_expected_failures/dom/insertTbodyRebuild1-expected.txt
	M	LayoutTests/storage/transaction_callback_exception_crash-expected.txt
	M	WebCore/ChangeLog
	M	WebCore/bindings/js/JSCustomSQLStatementCallback.cpp
	M	WebCore/bindings/js/JSCustomSQLStatementErrorCallback.cpp
	M	WebCore/bindings/js/JSCustomSQLTransactionCallback.cpp
	M	WebCore/bindings/js/JSCustomSQLTransactionErrorCallback.cpp
	M	WebCore/bindings/js/JSCustomVoidCallback.cpp
	M	WebCore/bindings/js/JSCustomXPathNSResolver.cpp
	M	WebCore/bindings/js/JSEventListener.cpp
	M	WebCore/bindings/js/ScheduledAction.cpp
	M	WebCore/bindings/js/ScriptController.cpp
	M	WebCore/bindings/objc/WebScriptObject.mm
	M	WebCore/page/Console.cpp
	M	WebCore/page/Console.h
Committed r35253