Commit Graph

23928 Commits

Author SHA1 Message Date
cbegle@netscape.com
3a08142630 * removed stuff from the idl file that caused warnings
* fixed a typo that caused a warning (nsIsupports)
* fixed values of constants that caused warnings
* use a macro instead of assinging a long long value directly

r=jband
1999-10-13 00:11:21 +00:00
norris@netscape.com
f585dc16b1 Fix unix build warning.
Reviewed by rogerl@netscape.com.
1999-10-12 22:48:17 +00:00
cbegle@netscape.com
911d8208eb new files.
new tests for xpconnect.  r=jband.
1999-10-12 00:12:43 +00:00
rogerl@netscape.com
0ac59822f4 NOT A PART OF SEAMONKEY BUILD
- fixed test ECMA references,
- added test to -002
1999-10-11 22:59:25 +00:00
rogerl@netscape.com
1cc282ce09 NOT A PART OF SEAMONKEY BUILD
- removed redundant test & fixed test for 'super' to detect syntax error
1999-10-11 22:38:40 +00:00
jband@netscape.com
627559e106 Much of this is under the auspices of bug 15794. r=mccabe.
- map xpcshell's 'quit()' to a loop exit rather than calling
'exit(0)' so that the cleanup and leak detection code will still
get called.

- add NS_InitXPCOM and NS_ShutdownXPCOM to xpcshell to run said
cleanup and leak detection code.

- use more NS_IF_* macros

- fix numerous places where code assumed that
nsXPConnect::GetXPConnect() does not add a new ref on the
xpconnect singleton object (the behavior changed some time back
but not all the uses did - brainfade!).

- fix nsXPCException::NewException to automatically trim
'dataless' native stackframes off of the front of a stack trace.
The old system of manually telling it how many frames to trim was
not working well. We really want the first frame showing to be an
'interesting' frame so that callers who get exceptions thrown at
them will see some useful information rather than an empty native
frame that represents (but says nothing about) some native frame
in the xpconnect runtime.

- remove an extra addref from the trimming loop in
nsXPCException::NewException.

- Stop building XPCJSStack objects. XPConnect stacks are singly
linked lists of XPCJSStackFrame objects with refcounted links. I
had this stupid idea that each object would have a refcounted
link to a XPCJSStack object that would tie together the lifetimes
of all objects in the chain. This was overcomplex and
unnecessary. The linked list was enough. Any frame without a
refcount deserved to be deleted because it is simply unreachable.
There was no reason to tie together all the lifetimes of each
object in the chain. So this has been simplified in a big way.

- fixed place in xpcthrower.cpp where we were leaking a refcount
on the xpconnect singleton each time an xpcexception was thrown.

- do cleanup and gc() at the end of xpctest_echo.js to use for
leak testing - all wrappers should go away.
1999-10-09 06:01:57 +00:00
cbegle@netscape.com
a78f2ba8a8 Adding new files. Tests for XPConnect. These files are not part of the
build.  R=jband@netscape.com
1999-10-08 20:45:37 +00:00
kipp@netscape.com
ea36a75c90 Cleanup moz-decl-counter usage and fix NS_LOG_ADDREF usage 1999-10-08 20:41:19 +00:00
warren@netscape.com
525b59f80b Fixed AddRef/Release problems to eliminate negative refcounts in Bloaty. 1999-10-08 01:49:06 +00:00
jband@netscape.com
75ce2b8c5a fix warning of old style C++ variable scope declared in 'for'. bug 15778. r=slamm 1999-10-08 00:11:05 +00:00
rogerl@netscape.com
aef9bf3075 Fixed build failures - these files are NOT part of the seamonkey build. 1999-10-07 20:45:27 +00:00
rogerl@netscape.com
b447398f9f Fixed error reporting to not smack the source line with a zero, but use
copyN instead - things were failing when very last line of input had an
error and didn't end with '\n'. r=mccabe
1999-10-07 20:44:40 +00:00
rogerl@netscape.com
2eed915871 Fixed build warnings by removing macros with '{..}'.
Made str_escape available for jsfile.
r=mccabe
1999-10-07 20:42:20 +00:00
rogerl@netscape.com
208b333d5e Making str_escape available for jsfile use. r=mccabe. 1999-10-07 20:41:15 +00:00
rogerl@netscape.com
065d8b6ca6 Bug #12168. Catch new Array(NaN). r=mccabe. 1999-10-07 20:40:17 +00:00
jband@netscape.com
e8c4a662aa - the rest of the fix for bug 14738 - detect JSErrors with
JSErrorReports when thrown as exceptions. Extract JSErrorReport
and convert to an xpcexception. This restores functionality that
was whacked when JS errors-as-exceptions was enabled in the JS
engine.
- add conversion support for string-with-length as part of array
support mentioned in bug 13420. All the array stuff is basically
in with minimal testcases. More comprehensive tests need to be
written to verify and tune the code.
- fix a broken #undef
- switch to using PR_Alloc/PR_Free internally in nsjsid where we
were using new/delete before. This is prompted by warren's change
to nsID::ToString that uses PR_Alloc were before it used new.
This fixes an alloc/delete mismatch detected by Purify.
r=mccabe
1999-10-06 21:35:27 +00:00
sspitzer@netscape.com
c8193fae49 fix for #15197 (and a whole bunch of duplicates).
fix by vidur, r=rogerl
1999-10-06 21:31:34 +00:00
cbegle@netscape.com
2859dcf0d9 tests for javascript errors as exceptions, a feature that was recently
added to the javascript engine.

not part of the build.
1999-10-06 20:45:44 +00:00
brendan@mozilla.org
3bebe32f60 Fix Object.prototype.toSource so it parenthesizes outermost-toSource literals for eval roundtrips. 1999-10-06 09:09:31 +00:00
brendan@mozilla.org
9b1ec81c38 Top-level ToSource function for primitive type roundtrips. 1999-10-06 06:37:55 +00:00
brendan@mozilla.org
582d5f9343 Fix two multi-threaded GC-rooting bugs:
- js_NewFunction wasn't initializing (clearing) JSFunction members before it
  linked the JSFunction to a JSObject that the GC could reach from a root.
- Make sure frame.scopeChain is cleared before linking frame via cx->fp, even
  though we set frame.scopeChain to some object later (another signal that we
  should rework js_Invoke to inline it and otherwise optimize it).
1999-10-06 06:29:43 +00:00
rogerl@netscape.com
e0f5ae5c17 Bug #14545 - get array length exceptions working with non-Number array
contructor arguments.
1999-10-05 22:11:57 +00:00
jband@netscape.com
d33a5101bf the JS engine part of the fix for bug 14738. This does two things: 1) expose the JSClass for JSError so that it is possible to detect from the outside if a given JSObject is of that JSError class, and 2) expose an api call via which the JSErrorReport can be extracted from a JSError (if present). This change required renaming the JSClass used for JSError, so many lines were touched 1999-10-05 21:07:23 +00:00
kipp@netscape.com
76c9883c3b r=jband; fixed a memory leak 1999-10-05 14:56:41 +00:00
waterson@netscape.com
5793bf8435 Bug 15367. Dump 'class' instead of 'file/line' for NS_LOG_REFCNT. r=shaver,dp 1999-10-05 00:07:54 +00:00
beard@netscape.com
483ac4ff31 changed from directly using "MSL ShLibRuntime.Lib" to using "NSLibraryStartup.o" to enable GC leak detector. r=smfr 1999-10-03 20:47:12 +00:00
beard@netscape.com
c3a82c2a86 changed from directly using "MSL DropInRuntime.Lib" to using "NSComponentStartup.o" to enable GC leak detector. r=smfr 1999-10-03 20:46:23 +00:00
beard@netscape.com
9f761cf67a changed from directly using "MSL ShLibRuntime.Lib" to using "NSLibraryStartup.o" to enable GC leak detector. r=smfr 1999-10-03 20:23:01 +00:00
norris@netscape.com
c71c60b2b9 Fix the following bugs:
14443 "Same origin" security policy may be circumvented using docu
14820 Fixing up the relationship between nsCodeBasePrincipal and n
14919 Crash in JS MM code
Reviewed by mstoltz, approved by scc.
1999-10-02 03:41:37 +00:00
kipp@netscape.com
aeca52e322 Convert to a module from a component 1999-09-30 21:47:04 +00:00
kipp@netscape.com
c0297ea0f2 Fixed shutdown related memory leaks 1999-09-30 21:12:33 +00:00
sfraser@netscape.com
41e3c8912b More type mismatch fixing for shavear 1999-09-29 03:07:27 +00:00
shaver@netscape.com
0ce5ac09a3 nsIRegistry scriptability update, r=dveditz,dp,alecf a=leaf,chofmann 1999-09-29 02:36:54 +00:00
dmose@mozilla.org
9df17aa445 update license boilerplate to NPL-1.1 dual-licensed with the GPL. a=brendan, r=brendan. 1999-09-28 23:12:09 +00:00
rogerl@netscape.com
53e24ebc9b Added -c <classpath> option to specify, you guessed it, a classpath. 1999-09-27 17:41:44 +00:00
shaver@netscape.com
0a9683bf96 unlock in fun_enumProperty, r,a=brendan 1999-09-27 08:24:36 +00:00
shaver@netscape.com
6742ca3fd7 properly unlock object, preventing ugly crash with |if (foo in noFoo)| 1999-09-27 06:04:54 +00:00
shaver@netscape.com
6c763f995e Fix leak of native path in AutoRegisterComponents.
Save registry data for failed components.
Make the loader work again (fix suffix length and init crash).
Better error reporting.
1999-09-27 02:22:25 +00:00
kipp@netscape.com
68c019717b new 1999-09-25 20:11:47 +00:00
kipp@netscape.com
789f770851 Init all variables, not just some of them 1999-09-25 20:07:20 +00:00
norris@netscape.com
46ef7eca02 Remove '.js' from SECTION. 1999-09-24 20:16:55 +00:00
mscott@netscape.com
c3787182b3 fix build bustage for dp. 1999-09-24 02:52:46 +00:00
dp@netscape.com
3a1adf5978 Fixing jsloader not to hold reference to component manager. (shaver)
Some initialization of members and checking at desctruction. (dp)
1999-09-24 01:37:44 +00:00
cbegle@netscape.com
763fff1fea update script to report an error if no tests passed. 1999-09-23 23:00:38 +00:00
cbegle@netscape.com
ccaa0f87fa just changing the section name so it doesn't break norris's script. 1999-09-23 22:59:20 +00:00
norris@netscape.com
f90b410b28 change FAILED color to red 1999-09-23 17:26:22 +00:00
norris@netscape.com
fb0f233506 Add test driver for rhino. 1999-09-23 17:24:14 +00:00
brendan@mozilla.org
8c9d931afc - Enable JS_HAS_NEW_OBJ_METHODS (Object.prototype.hasOwnProperty, isPrototypeOf
and propertyIsEnumerable) for JS1.5.
- Optimize obj_propertyIsEnumerable to avoid extra lookup code bloat, requiring
  fix to js_GetAttributes (unset out param on successful early retunr) that it
  exposed.
- Use more righteous else-if style in shaver's jsarray.c change.
1999-09-22 05:54:44 +00:00
shaver@netscape.com
c545f72719 new Array("string") should be ["string"], not silent failure (14545, r=brendan) 1999-09-22 04:36:28 +00:00
shaver@netscape.com
a2528d3d65 add componentType to nsIModule::RegisterSelf 1999-09-22 03:18:27 +00:00