Johnny Stenback wrote:
Phil H�hn (TL) wrote:
[...]
1) The first time it runs, as expected an exception occurs
(presumeably) because the pref "mytest.dir" does not exist(see below).
However when I step past the 'catch', I get
"ASSERTION: nsMemoryImpl::Alloc of 0: 'size', file <snip
snip>/xpcom/base/nsMemoryImpl.cpp, line 324"
a) I don't understand why it happens when I step past the catch,
b) Where is this 'alloc of 0 bytes' coming from (or is it the
javascript debugger itself and I should ignore it)?
Hmm, while that's not fatal, it should be fixed. Wanna file a bug in
bugzilla on that?
I may see if I can be more precise with the nature of the problem. A
similar message comes up quite often when I'm at a breakpoint and expand
a structure in the 'Local Variables' list on the left. It's happening a
lot and I just click 'ignore'. I've done a build clean, but maybe
something is still compiled strangely (I'm using .NET 2003).
2) After ignoring the above error, I get the directory picker and I
select C:\temp.
c) After stepping past the 2nd-to-last line, 'directory' is set to
"C:", not "C:\temp"! I can see this in prefs.js;
user_pref("mytest.dir", "C:");
[...]
var directory = fp.file.parent.QueryInterface(nsILocalFile);
Maybe loose the .parent there? :-)
Yes thanks, I hadn't got back to posting an update (incase anyone was
watching this thread) - after posting I realised the .parent should go,
and voila! It works correctly! The dir picker now comes up with the
previously used path also, which is great but mystifying - I guess when
I had the .parent in there something must have been malformed which
caused the dir picker to not work correctly when invoked.
Thanx
_______________________________________________
Mozilla-xpcom mailing list
[EMAIL PROTECTED]
http://mail.mozilla.org/listinfo/mozilla-xpcom