Граф коммитов

21998 Коммитов

Автор SHA1 Сообщение Дата
Sylvestre Ledru 42f6811d95 Bug 1519636 - Reformat recent changes to the Google coding style r=andi,media-playback-reviewers,necko-reviewers,padenot,dragana
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D148375
2022-06-07 12:32:55 +00:00
Mike Hommey 7ce663eb08 Bug 1772048 - Update rustc_version and semver crates. r=emilio,webdriver-reviewers,kinetik,whimboo
semver 1.0 doesn't and won't support Clone on semver::Error[1], so we
convert the mozversion error type to store the string version of the
error, which is an incompatible change requiring a version bump on the
crate.

1. https://github.com/dtolnay/semver/pull/280

Differential Revision: https://phabricator.services.mozilla.com/D147825
2022-06-07 10:01:32 +00:00
Steve Fink 20289c208c Bug 1661293 - Make nsJSContext::MaybePokeGC trigger eager minor GCs, and change the naming to support later adding EAGER_ALLOC_TRIGGER major GCs r=jonco,smaug
Differential Revision: https://phabricator.services.mozilla.com/D100368
2022-06-06 22:53:11 +00:00
Steve Fink 7a6aa8b314 Bug 1661293 - Move idle-time nursery GCs to a new nsJSContext::MaybePokeGC r=jonco,smaug
Differential Revision: https://phabricator.services.mozilla.com/D100367
2022-06-06 22:53:11 +00:00
Steve Fink 2a988c91ec Bug 1661293 - Rename JS::RunIdleGCTask -> JS::MaybeRunNurseryCollection and pass through the reason, also rename IDLE_TIME_COLLECTION -> EAGER_NURSERY_COLLECTION. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D139208
2022-06-06 22:53:10 +00:00
Seweryn Pajor e30e84c58a Bug 1772523 - Fix compiler warning about unused variable rv. r=xpcom-reviewers,jstutte
Differential Revision: https://phabricator.services.mozilla.com/D148308
2022-06-06 14:26:10 +00:00
Jens Stutte f31ba2bcd9 Bug 1772281 - Reduce the scope of the mMutex lock in ThreadEventQueue::SetObserver to avoid a potential recursive deadlock. r=xpcom-reviewers,jesup,nika
Differential Revision: https://phabricator.services.mozilla.com/D148249
2022-06-03 18:03:36 +00:00
Emilio Cobos Álvarez 9349aeea85 Bug 1771796 - Remove -moz-scrollbar-thumb-proportional. r=dholbert
It unconditionally matches on all platforms, so it's not returning any useful information.

Depends on D147689

Differential Revision: https://phabricator.services.mozilla.com/D147690
2022-06-02 11:58:18 +00:00
Olli Pettay 7cdb022402 Bug 1771718, let idle period be shorter when frame rate is very high, r=farre
Differential Revision: https://phabricator.services.mozilla.com/D147643
2022-06-02 10:40:54 +00:00
Nika Layzell d53b513ba3 Bug 1772171 - Move ToDouble back to nsTString, r=xpcom-reviewers,mccr8
Differential Revision: https://phabricator.services.mozilla.com/D147896
2022-06-01 17:45:14 +00:00
Seweryn Pajor 542f474cbc Bug 1769485 - Replace if statement checking if service manager is present with MOZ_DIAGNOSTIC_ASSERT. r=xpcom-reviewers,jstutte
Differential Revision: https://phabricator.services.mozilla.com/D147882
2022-06-01 17:15:06 +00:00
Mozilla Releng Treescript 8e705edc38 Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2022-05-30 11:42:22 +00:00
Steve Fink 819ec57dae Bug 1735434 - Gather additional information for cycle collection profiler markers r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D128316
2022-05-27 23:42:54 +00:00
Narcis Beleuzu e3d25251cc Backed out changeset 7f67e3634e8f (bug 1735434) for multiple failures/crashes on nsJSEnvironment.cpp . CLOSED TREE 2022-05-27 19:39:37 +03:00
Steve Fink ab9c7c302b Bug 1735434 - Gather additional information for cycle collection profiler markers r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D128316
2022-05-27 15:44:22 +00:00
Kagami Sascha Rosylight 846680d799 Bug 1757635 - Part 1: Add `using ::ImplCycleCollectionUnlink` inside NS_IMPL_CYCLE_COLLECTION_WITH_JS_MEMBERS r=mccr8
Otherwise the global ImplCycleCollectionUnlink for JS members are shadowed by mozilla::dom::ImplCycleCollectionUnlink and can't be used.

Bug 1756794 is to move all the impls to the single namespace to prevent this, but that requires verbose changes, and currently the only affected uses are from these macros.

Differential Revision: https://phabricator.services.mozilla.com/D147234
2022-05-25 23:41:25 +00:00
Cathy Lu 803a4e8449 Bug 1721220 - Add BAD_STS_CERT error r=geckoview-reviewers,nika,agi,owlish
Differential Revision: https://phabricator.services.mozilla.com/D146234
2022-05-25 17:51:11 +00:00
Gijs Kruitbosch a3f9a3f4e2 Bug 1707462 - expose Windows' localized file display names through XPCOM, r=mhowell
Differential Revision: https://phabricator.services.mozilla.com/D143480
2022-05-23 21:57:02 +00:00
Barret Rennie 868f461b18 Bug 1769094 - nsLocalFile::Append{,RelativePath} should throw when appending .. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146228
2022-05-21 23:03:51 +00:00
Emilio Cobos Álvarez 0076bed412 Bug 1770532 - Ensure options in listbox selects are not stacking contexts by default. r=dholbert
We could have a different property or something but this seems
reasonable as well probably.

Differential Revision: https://phabricator.services.mozilla.com/D146994
2022-05-21 17:23:24 +00:00
Chris Peterson c686ea7b47 Bug 1770107 - Disambiguate char16_t* operator== overloads in MinGW build for C++23. r=xpcom-reviewers,nika
C++23 is stricer about matching operator== overloads than C++17 and char16ptr_t's implicit constructor causes some overload confusion. We can disambigutate the operator== overloads by adding typed local variables without needing type casts.

xpcom/io/nsLinebreakConverter.cpp:447:17: error: use of overloaded operator '!=' is ambiguous (with operand types 'nsTSubstring<char16_t>::iterator' (aka 'char16_t *') and 'typename raw_type<char16_t, int>::type' (aka 'char16ptr_t'))
 if (stringBuf != aIoString.get()) {
     ~~~~~~~~~ ^  ~~~~~~~~~~~~~~~
mozilla/Char16.h:95:8: note: candidate function (with reversed parameter order)
 bool operator==(const char16ptr_t& aOther) const {
      ^
xpcom/io/nsLinebreakConverter.cpp:447:17: note: built-in candidate operator!=(const char16_t *, const char16_t *)
 if (stringBuf != aIoString.get()) {
               ^
xpcom/io/nsLinebreakConverter.cpp:447:17: note: built-in candidate operator!=(const volatile char16_t *, const volatile char16_t *)
xpcom/io/nsLinebreakConverter.cpp:447:17: note: built-in candidate operator!=(const void *, const void *)
xpcom/io/nsLinebreakConverter.cpp:447:17: note: built-in candidate operator!=(const volatile void *, const volatile void *)

Differential Revision: https://phabricator.services.mozilla.com/D146772
2022-05-20 06:06:19 +00:00
Butkovits Atila 7bbda20470 Backed out changeset 37142ab92a09 (bug 1769094) for causing gecko view failures at TestFilePreferencesUnix. CLOSED TREE 2022-05-20 08:25:24 +03:00
Barret Rennie f32c9fbea0 Bug 1769094 - nsLocalFile::Append{,RelativePath} should throw when appending .. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146228
2022-05-20 03:03:27 +00:00
Narcis Beleuzu 8f30325b72 Backed out 2 changesets (bug 1767396) for wpt failures on iframe-focus-event-after-iframe-gets-focus.html CLOSED TREE
Backed out changeset 39b9ecc2224a (bug 1767396)
Backed out changeset 77aa60771db2 (bug 1767396)
2022-05-20 02:54:56 +03:00
Gerald Squelart 74d28327be Bug 1767396 - Don't wake up the timer thread when removing timers - r=florian,smaug
Differential Revision: https://phabricator.services.mozilla.com/D146031
2022-05-19 20:31:25 +00:00
Gerald Squelart 2275810480 Bug 1767396 - AUTO_TIMERS_STATS - r=florian
This will help during development, to measure before/after times in TimerThread functions.

Differential Revision: https://phabricator.services.mozilla.com/D146030
2022-05-19 20:31:24 +00:00
Iulian Moraru 4f7b7b518b Backed out changeset 6f5cd18d3b57 (bug 1769094) for causing gtest failures on TestFilePreferencesUnix.Simple. 2022-05-18 20:41:06 +03:00
Barret Rennie 06c8e5da3d Bug 1769094 - nsLocalFile::Append{,RelativePath} should throw when appending .. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146228
2022-05-18 16:45:44 +00:00
Kershaw Chang ed4399816c Bug 1754975 - Introduce a new error code for blocking a non-local connection, r=necko-reviewers,dragana
Differential Revision: https://phabricator.services.mozilla.com/D146281
2022-05-18 15:31:07 +00:00
Jon Coppeard 750da6ab68 Bug 1768734 - Make sure JS holders are cleared before a shutdown GC r=mccr8
Previously this was optimized to trace only gray roots in collecting zones, but
there was a bug in that it also skipped clearing roots because this happens
before the start of GC when zones are selected for collection.

Instead, make sure we only perform this optimziation when marking.

Differential Revision: https://phabricator.services.mozilla.com/D146585
2022-05-18 09:04:05 +00:00
Andrew McCreight 5b3d5c09ae Bug 1514936, part 3 - Remove NS_ERROR_NO_AGGREGATION which is no longer used. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146458
2022-05-17 20:24:20 +00:00
Andrew McCreight fa8bfd1245 Bug 1514936, part 2 - Drop the outer arguments from static components. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146457
2022-05-17 20:24:19 +00:00
Andrew McCreight c8c5c819df Bug 1514936, part 1 - Remove the outer argument to nsIFactory::createInstance. r=xpcom-reviewers,preferences-reviewers,nika,Gijs
This patch won't actually build, because a few bits of code are used
for both nsIFactory::createInstance and static components, and static
components are not fixed until the next patch.

The first place is nsLoadGroupConstructor, which uses an nsIFactory
macro to create a static component constructor. (This could be worked
around by expanding the macro to the state before this patch.)

The other issue is that nsAppShellConstructor is used in an nsIFactory
on OSX, but as a static component on all other platforms. This could
be worked around by wrapping nsAppShellConstructor in an adaptor that
passes in the extra null argument to nsAppShellConstructor.

Differential Revision: https://phabricator.services.mozilla.com/D146456
2022-05-17 20:24:19 +00:00
Andrew McCreight 01913de302 Bug 1769442 - Remove nsIFactory::lockFactory, breaking compatibility with IClassFactory. r=xpcom-reviewers,Jamie,necko-reviewers,kershaw,nika
nsIFactory is binary compatible with Windows COM's IClassFactory,
but nothing seems to depend on it. This patch removes the test
for compatibility, TestCOM, and removes the lockFactory
method that isn't otherwise needed.

Differential Revision: https://phabricator.services.mozilla.com/D146386
2022-05-16 22:38:51 +00:00
Nika Layzell 59f3f40567 Bug 1767517 - Part 2: Annotate nsPipe for the thread safety analysis, r=jesup,xpcom-reviewers,KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D145394
2022-05-16 20:40:49 +00:00
Nika Layzell 7d84828a9c Bug 1769332 - Generate XPCOM error code lists for Java, r=geckoview-reviewers,agi,calu
This allows us to replace a number of magic numbers in the
WebRequestError code with automatically generated constants which are
guaranteed to be kept up to date.

This build script is able to run early enough during the build step as
generated files which take a `.jinja` file as an argument are hard-coded
to be run during the pre-export phase for Android builds. As it is just
as simple python script with no other dependencies, this shouldn't
impact geckoview build performance even when using build artifacts.

Differential Revision: https://phabricator.services.mozilla.com/D146356
2022-05-16 18:01:19 +00:00
Kagami Sascha Rosylight c0ac0addf7 Bug 1769290 - Part 5: Apply mozilla-js-handle-rooted-typedef against xpcom r=xpcom-reviewers,mccr8
Depends on D146454

Differential Revision: https://phabricator.services.mozilla.com/D146469
2022-05-16 17:20:30 +00:00
Kagami Sascha Rosylight 2093ec97cf Bug 1769290 - Part 3: Use fully qualified JS types in xpidl r=xpcom-reviewers,mccr8
Depends on D146439

Differential Revision: https://phabricator.services.mozilla.com/D146453
2022-05-16 17:20:30 +00:00
Randell Jesup 00859f1620 Bug 1762959 - xpcom/io thread-safety annotations r=nika
Differential Revision: https://phabricator.services.mozilla.com/D142066
2022-05-16 13:54:05 +00:00
Randell Jesup d3b15de2f1 Bug 1762920: remove whitelist from xpcom/crashreporter r=nika,gsvelto
Differential Revision: https://phabricator.services.mozilla.com/D142843
2022-05-16 01:37:39 +00:00
Autumn on Tape ba819ad54d Bug 1422312 - implement 'update' media feature r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D146338
2022-05-14 13:46:41 +00:00
Iulian Moraru 8cfdac9a59 Backed out changeset eb32954c1f4c (bug 1769094) for causing multiple failures. 2022-05-13 21:00:50 +03:00
Jens Stutte aa8c3727dc Bug 1766572: Part 3 - Make nsTerminator aware of late shutdown phases. r=xpcom-reviewers,nika
In order to get better shutdown hang reporting, we want to distinguish also the last phases, namely `XPCOMShutdownThreads`, `XPCOMShutdownMainThread` and `CCPostLastCycleCollection`.
This also makes `XPCOMShutdownNotified()` obsolete and we need to slightly re-arrange the watchdog function.

Differential Revision: https://phabricator.services.mozilla.com/D145433
2022-05-13 15:47:53 +00:00
Jens Stutte f02175db9d Bug 1766572: Part 2 - Synchronize KillClearOnShutdown phases with AdvanceShutdownPhase. r=xpcom-reviewers,dthayer,nika
The concept of a shutdown phase is meant to be a finite and named period of time where:

1. we can query if we are in or beyond a given phase
2. we may want to do a fast shutdown
3. we inform the terminator that we reached the next phase
4. if needed/wanted, we notify observers of the associated topic
5. we KillClearOnShutdown smart pointers associated with this phase
6. we do any further, phase-individual cleanup until the next phase starts

`AdvanceShutdownPhase(WithoutNotify)` now provides the functionality for 1. through 5. and must be the only place that calls `KillClearOnShutdown` in order to avoid misalignments.
In doing so, it becomes also the only caller of `MaybeFastShutdown`.

Please refer to bug 1768581 as working on this patch made us think if we should re-work the order inside AdvanceShutdownPhase.

Differential Revision: https://phabricator.services.mozilla.com/D145083
2022-05-13 15:47:52 +00:00
Jens Stutte 13675ac0e6 Bug 1766572: Part 1 - Remove obsolete ShutdownPhase::XPCOMShutdownLoaders. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D145082
2022-05-13 15:47:52 +00:00
Emilio Cobos Álvarez 87ff5a5d8d Bug 1768418 - Move various methods from nsTString to nsTSubstring/nsTStringRepr. r=xpcom-reviewers,nika
No reason these don't work on substrings.

Remove StripChars since it has an existing nsTSubstring version. Make
callers use rightly-typed characters for those.

Differential Revision: https://phabricator.services.mozilla.com/D145864
2022-05-13 15:39:19 +00:00
Barret Rennie 9dea84af2a Bug 1769094 - nsLocalFile::Append{,RelativePath} should throw when appending .. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D146228
2022-05-13 15:08:47 +00:00
Nika Layzell 873e958e4f Bug 1754004 - Part 18: Ensure AsyncWait callbacks are cleared when NS_AsyncCopy completes, r=xpcom-reviewers,mccr8
When the NS_AsyncCopy completes, there may still be outstanding
AsyncWait callbacks which have not been invoked yet, due to two
AsyncWait callbacks being registered each time Process() yields (one to
wait for the blocked stream, and the other with WAIT_CLOSURE_ONLY to
handle errors), and only one callback being needed to resume processing.

This change ensures that any outstanding AsyncWait callbacks are
cancelled, breaking references from the streams to the
nsAStreamCallback. Some streams (such as nsPipe and DataPipe) may also
leak if there are oustanding AsyncWait callbacks, due to the need to
keep the stream alive so it can be passed into the callback, which this
helps avoid.

Previously leaks were largely avoided due to the call to `Close()`
cancelling the callbacks for us, however not all callsites specify to
close the source/sink.

This should also help avoid an unnecessary dispatch after the copy
completes due to our AsyncWait callback being invoked when the
source/sink stream is closed.

Differential Revision: https://phabricator.services.mozilla.com/D146130
2022-05-13 14:16:16 +00:00
Nika Layzell b82512de01 Bug 1754004 - Part 17: Keep pipe streams alive so long as there's a callback registered, r=asuth
If we don't do this, we can encounter issues where we'll spuriously close the
stream when the last reference to the input stream is dropped while an
AsyncWait is still pending.

Differential Revision: https://phabricator.services.mozilla.com/D145672
2022-05-13 14:16:16 +00:00
Nika Layzell d5fa382918 Bug 1754004 - Part 15: Don't track mOriginalInput in nsPipe, r=asuth
As discovered by TSan, this member could be raced on in some edge-cases if
cloned pipe streams raced on multiple threads to be destroyed. This change
instead moves the `nsIPipe` implementation to be on a seperate type from
`nsPipe`, allowing `mOriginalInput` to no longer need to be tracked.

This technically has slightly different behaviour than the previous
implementation for JS code, as code keeping the `nsIPipe` alive will now also
be keeping the output stream reference alive directly, rather than only holding
the `nsIPipe`, meaning that `pipe.outputStream` can be read multiple times
independently without implicitly closing the underlying stream. Based on a
quick read of the few remaining uses of `nsIPipe` in JS code, I don't think
this will be an issue, and it may actually be more intuitive and consistent.

Differential Revision: https://phabricator.services.mozilla.com/D145362
2022-05-13 14:16:15 +00:00