Closed Bug 85968 Opened 24 years ago Closed 24 years ago

Venkman should be able to handle JS components

Categories

(Other Applications Graveyard :: Venkman JS Debugger, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: peterv, Assigned: rginda)

Details

Attachments

(2 files)

but it doesn't :(. Problem is the url to the source file is actually a local path, which should be turned into a file:// url.
Attached patch This helpsSplinter Review
With this patch, my breakpoint is hit and I see the source :). One other problem: Venkman doesn't handle Macintosh line-endings because of the line var ary = data.split("\n"); in venkman-debugger.js. Mac would need split("\r") of course. Minor problem, I just changed my components line-endings to \n but it should probably be fixed sometime.
Moving to .split(/\s+/) could fix the mac whitespace problem. url.search (/^\w+:\/\//) == -1) is better, as it should find only protocols at the start of the URL. Axel
OS: Mac System 8.5 → All
Hardware: Macintosh → All
Well, here's what *I* think ;) 1) modify the js component loader to use the file:// url instead of the native path, as the filename associated with the JSScript* (dougt implemented nsLocalFile::GetURL on mac and unix for bug 73845.) 2) split on the meta-character for <end-of-line>, instead of a literal "\n". 3) strip out any control characters left over. I can't think of a situation where using file:// as the filename instead of a native path would cause trouble. Can anyone else?
Status: NEW → ASSIGNED
works great for me. I can load both js components and local files allright on solaris. Axel
I can't think of a situation where using file:// as the filename instead of a native path would cause trouble. Can anyone else? Sure :-) MacOS =). you can have at least two disks w/ the same name. joy =). It should be documented in the file protocol implementation for macos.
Using a native path isn't going to solve that problem, we're storing the filename as plain text either way. hard disk:mozilla:components:foo.js is just as exposed to mac's braindead file system as file://hard+disk/mozilla/components/foo.js.
shaver/ brendan, care to sr=? dbradley, r=?
r=dbradley
sr=shaver.
Thanks muchly. Fix checked in.
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Product: Core → Other Applications
Product: Other Applications → Other Applications Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: