Commit Graph

146 Commits

Author SHA1 Message Date
Bobby Holley
3908f72e5a Bug 870043 - Add support for scripted operation callbacks in XPCShell. r=mrbkap 2013-07-24 15:33:31 -07:00
Bobby Holley
ea7a9f6f09 Bug 889911 - Switch xpcshell to SystemErrorReporter with a little bit of special magic. r=mrbkap
XPCShell currently overrides all the JSContexts whose creation it observes with
its own custom error reporter. This reporter does all sorts of funny things which
we try to clean up for the most part. But there are a few very intricate
considerations at play.

First, the old xpcshell error reporter does some mumbo jumbo with the
XPCCallContext stack to try to guess whether some other code might catch the
exception. This is total garbage on a number of fronts, particularly because
the XPCCallContext stack has no concept of saved frame chains, nested event
loops, sandbox boundaries, origin boundaries, or any of the myriad of
complicating factors that determine whether or not an exception will propagate.

So we get rid of it. But this causes some crazy debugger tests to fail, because
they rely on an exception from uriloader/exthandler/nsHandlerService.js getting
squelched, and can't handle anybody reporting errors to the console service at
the particular moment of contortionism when the exception is raised. So we need
to introduce an explicit mechanism to disable the error reporter here to keep
things running.

Second, we have to be very careful about tracking the return status of the
xpcshell binary. The old code would simply flag an error code if the error
handler was invoked, and we can mostly continue to do that. But there are some
complications. See the comments.

Finally, we don't anything analogous in XPCShellEnvironment, because I have
patches in bug 889714 to remove its state-dependence on the error reporter.
I'll switch it to SystemErrorReporter in that bug.
2013-07-16 20:38:44 -07:00
Ryan VanderMeulen
ec49bf763f Backed out 10 changesets (bug 889911, bug 889714) due to merge conflicts on a CLOSED TREE.
Backed out changeset 1a1a536121da (bug 889714)
Backed out changeset 2cd88ef9eea5 (bug 889714)
Backed out changeset 489723887eca (bug 889714)
Backed out changeset 2b38ce22cf97 (bug 889714)
Backed out changeset 87b0a59a5d51 (bug 889714)
Backed out changeset 13229bab2ba4 (bug 889714)
Backed out changeset 234bd6d1fbed (bug 889714)
Backed out changeset 4f5f62284917 (bug 889714)
Backed out changeset 18537c4436c7 (bug 889911)
Backed out changeset ca7060ab1588 (bug 889911)
2013-07-16 21:16:31 -04:00
Bobby Holley
b5be668356 Bug 889911 - Switch xpcshell to SystemErrorReporter with a little bit of special magic. r=mrbkap
XPCShell currently overrides all the JSContexts whose creation it observes with
its own custom error reporter. This reporter does all sorts of funny things which
we try to clean up for the most part. But there are a few very intricate
considerations at play.

First, the old xpcshell error reporter does some mumbo jumbo with the
XPCCallContext stack to try to guess whether some other code might catch the
exception. This is total garbage on a number of fronts, particularly because
the XPCCallContext stack has no concept of saved frame chains, nested event
loops, sandbox boundaries, origin boundaries, or any of the myriad of
complicating factors that determine whether or not an exception will propagate.

So we get rid of it. But this causes some crazy debugger tests to fail, because
they rely on an exception from uriloader/exthandler/nsHandlerService.js getting
squelched, and can't handle anybody reporting errors to the console service at
the particular moment of contortionism when the exception is raised. So we need
to introduce an explicit mechanism to disable the error reporter here to keep
things running.

Second, we have to be very careful about tracking the return status of the
xpcshell binary. The old code would simply flag an error code if the error
handler was invoked, and we can mostly continue to do that. But there are some
complications. See the comments.

Finally, we don't anything analogous in XPCShellEnvironment, because I have
patches in bug 889714 to remove its state-dependence on the error reporter.
I'll switch it to SystemErrorReporter in that bug.
2013-07-16 18:04:49 -07:00
David Anderson
e90c94517c Rewrite CPOWs to use one actor per process (bug 853209, r=billm,bholley,smaug). 2013-07-03 00:24:32 -07:00
Bobby Holley
d12dacd7b6 Bug 880917 - Add an API to mutate the version on the compartment and use it from the shells. r=luke 2013-06-29 09:11:19 -06:00
Bobby Holley
f77eb1e574 Bug 880917 - Convert JS_SetVersion API consumers to per-compartment versions. r=luke 2013-06-29 09:11:18 -06:00
Bobby Holley
f5f7bf3be5 Bug 880917 - Generalize JS_NewGlobalObject API to take CompartmentOptions. r=luke
This will be useful for versioning, as well as JIT options and all the other
stuff that eventually needs to move out of the JSContext.
2013-06-29 09:11:17 -06:00
Jan Varga
4d7db5e807 Bug 884936 - Add Blob/File support to xpcshell. r=bent 2013-06-21 17:15:46 +02:00
Jon Coppeard
2632590a6e Bug 885310 - 2 Rename JSHandleFoo in js directory r=bholley 2013-06-21 14:12:46 +01:00
Jon Coppeard
63011a7ca0 Bug 884371 - Remove JSMutableHandleXXX from the js directory r=bholley 2013-06-19 11:32:27 +01:00
Benjamin Peterson
ca23ac22c9 Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : 34f95fc6017d3f3f4f091083debacbd466b51bf6
2013-06-11 12:49:11 -07:00
Ryan VanderMeulen
23aa576486 Backed out changeset 1df122edcf0d (bug 823978) for bustage (again).
CLOSED TREE (again)
2013-06-11 15:27:46 -04:00
Benjamin Peterson
1871556ad9 Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : 1396c8ec5bd99ab35343cfff2b87d22955671243
2013-06-11 11:30:18 -07:00
Ryan VanderMeulen
9855cde4ef Backed out changeset 7e69e102a432 (bug 823978) for bustage.
CLOSED TREE
2013-06-11 14:28:17 -04:00
Benjamin Peterson
e459c55070 Bug 823978 - Rename JSOPTION_STRICT to JSOPTION_EXTRA_WARNINGS. r=Waldo
--HG--
extra : rebase_source : f5c0e9c743dadb0431eacef6b46b6e274264d3aa
2013-06-11 10:55:21 -07:00
Terrence Cole
d47d3bb135 Bug 880392 - Fix use-after free with exact rooting in XPCShell; r=sfink
--HG--
extra : rebase_source : a509e84b7165b8a40f4a06e006dfc614665eef2c
2013-06-07 11:34:57 -07:00
Bobby Holley
7a7cb3b991 Bug 877478 - Remove SetSecurityManagerForJSContext and related APIs. r=mrbkap
The only consumers here were the shells, which we've now fixed.
2013-06-04 19:56:43 -07:00
Bobby Holley
ec2aeea66b Bug 877478 - Remove FullTrustSecMan junk. r=mrbkap
This stuff shouldn't be necessary anymore. The default security manager should
do the right thing given for script running in the scope of a BackstagePass.
2013-06-04 19:56:42 -07:00
Bobby Holley
91448a9dac Bug 868130 - Remove the lion's share of JSAutoRequests in gecko. r=gabor
There are still a handful that either are used with other runtimes, or that
happen very early/late in cx the lifetime of various things where it doesn't
necessarily make sense to have a cx on the stack. This should definitely ensure
that we're not doing double-duty with the nsCxPusher change, though.
2013-05-22 10:05:28 -06:00
Bobby Holley
20dd5cfed6 Bug 868130 - Remove the dependencies of the nsCxPusher machinery on nsContentUtils, use nsCxPusher in xpcshell, and privatize APIs. r=gabor
No more xpc::danger, for now. ;-)
2013-05-22 10:05:26 -06:00
Jan de Mooij
d1d46a2f99 Bug 857845 part 3 - Remove JM JSAPI flags, memory reporters and browser prefs. r=djvj
--HG--
extra : rebase_source : 8b2ed85801fcd8c8fd0fc16a89b1a275add1a310
2013-05-22 14:50:45 +02:00
Boris Zbarsky
85b06d58a3 Bug 873735 part 2. Change nsIXPConnectJSObjectHolder::GetJSObject to return a JSObject*. r=bholley 2013-05-20 08:44:18 -04:00
David Zbarsky
970837a16a Bug 867459: Root xpcshell.cpp r=terrence 2013-05-01 18:43:53 -04:00
Terrence Cole
e417ffe01a Bug 860050 - Remove JSMutableHandleObject typedef; r=bz,jonco 2013-04-16 16:20:44 -07:00
Bobby Holley
ee8843b983 Bug 865729 - Remove Push/Pop from public API. r=gabor 2013-04-29 11:16:22 -07:00
Xin Zhang
5d0104d77b Bug 857385 - Make various JSFunctionSpec arrays const. r=waldo
--HG--
extra : rebase_source : 24141998ffad3b0e6bad98b6fc0ce3754e448d5b
2013-04-22 14:15:49 -07:00
Jeff Walden
f9d3bc73ed Bug 858677 - Fix up code not built by SpiderMonkey to use the newly-changed deletion signatures. r=bholley, r=billm 2013-04-05 21:22:55 -07:00
Gabor Krizsanits
c38a4cd7da Bug 820170 - Turning BackstagePass into non-singleton. r=bholley 2013-04-04 11:27:38 +02:00
Bill McCloskey
a3cea08b3a Bug 759585 - Zones (r=jonco,bhackett,njn,dvander,luke,bz,mccr8,bholley) 2013-03-16 20:36:37 -07:00
Luke Wagner
e48f129191 Bug 840282 - OdinMonkey (sr=dmandelin)
--HG--
extra : rebase_source : 4a3869dca32755abb58bbd3d9a06599e61b397f2
2013-03-15 02:29:02 -07:00
Nicholas Nethercote
a2434f94d8 Bug 842438 (part 1) - Remove @line support from SpiderMonkey. r=benjamin.
--HG--
extra : rebase_source : 38502ad54c97a0e16e6396f9f39df31b73d0e289
2013-03-11 14:27:34 -07:00
Jon Coppeard
8d5fd16382 Bug 848395 - GC: Move Rooted to JS namespace - rename js::Rooted to JS::Rooted outside SpiderMonkey r=terrence
--HG--
extra : rebase_source : 35cbf3cc4da4598c2e9e6975028ef397718849db
2013-03-06 16:41:43 +00:00
Ed Morley
fe417ad697 Backed out changeset 28ef4bdff455 (bug 848395) 2013-03-07 13:03:35 +00:00
Jon Coppeard
fa71007e65 Bug 848395 - GC: Move Rooted to JS namespace - rename js::Rooted to JS::Rooted outside SpiderMonkey r=terrence
--HG--
extra : rebase_source : 866879df05e3ec3f8e93570eb3f6b71103636b41
2013-03-06 16:41:43 +00:00
Chuck Lee
e329997fd6 Bug 835719 - 0003. Rename JSAutoByteString.encode() to encodeLatin1(). r=terrence 2013-02-21 17:48:17 +08:00
Jonathan Kew
5219b8ae03 backout cset 4ede352670cd (bug 759585) on a CLOSED TREE on suspicion of making windows reftests so slow that they timeout and burn 2013-02-22 09:36:41 +00:00
Bill McCloskey
c330d96d13 Bug 759585 - Change the granularity of collection from compartment to zone (r=jonco,bhackett,njn,dvander,mccr8,bz,luke,bholley) 2013-02-21 18:23:47 -08:00
Jeff Walden
0e302a5094 Bug 826009 - Move locale callback info, default locale, etc. data and APIs to be JSRuntime-centered. f=bholley, r=jorendorff
--HG--
extra : rebase_source : 35317f4c29e9dd70e7d4fd1292027cfd51ce2675
2013-02-07 18:04:11 -08:00
Mike Hommey
362f974085 Bug 793767 - Use the executable file location to derive the update root. r=rstrong 2013-02-08 15:58:52 +01:00
Nicholas Nethercote
524f6ea9b5 Bug 788293 - Remove e4x support. r=jorendorff,terrence,evilpie.
Ding dong!  The witch is dead!
2013-01-24 21:24:57 -08:00
Phil Ringnalda
b4eec14ca3 Back out 66882ea6f8c7 (bug 788293) and 32f09cb3c7b6 (bug 834090) for bustage
CLOSED TREE
2013-01-31 22:29:30 -08:00
Nicholas Nethercote
ae7837bdef Bug 788293 - Remove e4x support. r=jorendorff,terrence,evilpie.
Ding dong!  The witch is dead!

--HG--
extra : rebase_source : 7574f5620e303c25120fcfc8ceb2099ad75c8f1b
2013-01-24 21:24:57 -08:00
Jeff Walden
e03bb4799c Bug 824217 - Remove some easy-to-remove tests of JSRESOLVE_ASSIGNING. r=bz
--HG--
extra : rebase_source : 2605d559d48b9ccd985bd860f13ab7b1b53ab048
2012-12-19 19:32:34 -05:00
Josh Matthews
8c6ec75b56 Backed out changeset 40c1df07b407 (bug 824217) 2012-12-28 19:13:36 -05:00
Jeff Walden
efc17396e8 Bug 824217 - Remove some easy-to-remove tests of JSRESOLVE_ASSIGNING. r=bz 2012-12-19 19:32:34 -05:00
Jim Mathies
10c1c2ce73 Bug 817881 - Move test plugin to dist/plugins, and touch up tests and test logic to support the change. r=glandium, dtownsend 2012-12-17 12:08:00 -06:00
Jim Mathies
0c8f97af4e Bug 817076 - Update xpcshell's NS_APP_PREFS_DEFAULTS_DIR_LIST so that it returns the app dir if specified. r=glandium 2012-12-05 16:35:34 -06:00
Geoff Brown
927ee7925e Bug 815699 - Check for null mGREDir in xpcshell dir provider; r=jimm 2012-11-27 11:44:24 -07:00
Nicolas B. Pierron
b4a74f1cc8 Bug 810062 - Toggle JSOPTIONs before the compartment creation. r=bhackett 2012-11-19 18:07:20 -08:00