Closed Bug 326180 Opened 19 years ago Closed 19 years ago

When a bookmarklet or JS Console command causes an error, "source file" link is a bogus view-source:javascript: URL

Categories

(Toolkit Graveyard :: Error Console, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 318245

People

(Reporter: hickeyj, Unassigned)

Details

User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1) Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060206 Firefox/1.6a1 Evaluating an invalid JavaScript command in the console, such as "Hello" prints "Source File: javascript:hello" to the output window. Clicking on the "javascript:hello" link opens an empty text editor and the following prints to the JavaScript console output window: Error: uncaught exception: [Exception..."Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE)[nsIWebNavigation.loadURI]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame::chrome://global/content/viewSource.js:: viewSource:: line145" data: no] Reproducible: Always Steps to Reproduce: 1. Type “Hello” into the JavaScript Console input field and click “Evaluate”. An error message should be printed to the output window. 2. Click on the Source File link ("javascript:hello") in the output window Actual Results: An empty text editor opens and the following is printed to the JavaScript console output window: Error: uncaught exception: [Exception..."Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE)[nsIWebNavigation.loadURI]" nsresult: "0x80070057 (NS_ERROR_ILLEGAL_VALUE)" location: "JS frame::chrome://global/content/viewSource.js:: viewSource:: line145" data: no] Expected Results: The evaluation window should indicate that an error occurred, and should tell the user that “Hello” is not a valid JavaScript command, but there should not be a link to an empty text editor in the output window.
*** This bug has been marked as a duplicate of 318245 ***
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → DUPLICATE
Summary: Clicking on Source File link to invalid JavaScript command prints Uncaught Exception → When a bookmarklet or JS Console command causes an error, "source file" link is a bogus view-source:javascript: URL
Product: Firefox → Toolkit
Product: Toolkit → Toolkit Graveyard
You need to log in before you can comment on or make changes to this bug.