Commit Graph

677 Commits

Author SHA1 Message Date
Iulian Moraru
7a59e75c46 Backed out 8 changesets (bug 1839051) for causing assertion failures on NotificationController.cpp. CLOSED TREE
Backed out changeset 94a4c163e417 (bug 1839051)
Backed out changeset 5204b97e40bc (bug 1839051)
Backed out changeset 8443a22a399d (bug 1839051)
Backed out changeset 2ab1e27d5945 (bug 1839051)
Backed out changeset 20a850a4fd7e (bug 1839051)
Backed out changeset 658568fe9662 (bug 1839051)
Backed out changeset 82525b11a7c3 (bug 1839051)
Backed out changeset 720e6863c41a (bug 1839051)
2023-12-04 22:34:25 +02:00
Jens Stutte
b612507fab Bug 1839051 - Remove include nsQuickSort.h from some more files. r=emilio
Depends on D182724

Differential Revision: https://phabricator.services.mozilla.com/D182731
2023-12-04 18:33:42 +00:00
Jens Stutte
924e499eb1 Bug 1839051 - Use nsTArray::Sort for Sort and have also StableSort in nsCOMArray. r=necko-reviewers,kershaw,emilio,places-reviewers,mak
Depends on D181344

Differential Revision: https://phabricator.services.mozilla.com/D181889
2023-12-04 18:33:40 +00:00
Mark Banner
49a88d8bb7 Bug 1844125 - Remove more bits of old translations code. r=gregtatum
Differential Revision: https://phabricator.services.mozilla.com/D192154
2023-10-30 16:20:55 +00:00
Sylvestre Ledru
e19d8da8b9 Bug 1856795 - ride along: use = default; on some recently modified files r=emilio
More on:
https://clang.llvm.org/extra/clang-tidy/checks/modernize/use-equals-default.html

Command:
L=$(hg export -r tip|grep +++|cut -d/ -f2-)
./mach static-analysis check --checks="-*, modernize-use-equals-default" --fix $L

Differential Revision: https://phabricator.services.mozilla.com/D191016
2023-10-15 15:29:03 +00:00
Sylvestre Ledru
b0fe72dee5 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-15 15:29:02 +00:00
Cristina Horotan
7388749830 Backed out 2 changesets (bug 1856795) for causing build bustage at BasicEvents.h CLOSED TREE
Backed out changeset 1d98b028923a (bug 1856795)
Backed out changeset eae2ac93e17c (bug 1856795)
2023-10-14 21:42:14 +03:00
Sylvestre Ledru
ba5da021b1 Bug 1856795 - ride along: use = default; on some recently modified files r=emilio
More on:
https://clang.llvm.org/extra/clang-tidy/checks/modernize/use-equals-default.html

Command:
L=$(hg export -r tip|grep +++|cut -d/ -f2-)
./mach static-analysis check --checks="-*, modernize-use-equals-default" --fix $L

Differential Revision: https://phabricator.services.mozilla.com/D191016
2023-10-14 17:34:27 +00:00
Sylvestre Ledru
4a97019e39 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-14 17:34:26 +00:00
Emilio Cobos Álvarez
d02e297b2d Bug 1624819 - Remove TaskCategory and other quantum dom remnants. r=smaug,media-playback-reviewers,credential-management-reviewers,cookie-reviewers,places-reviewers,win-reviewers,valentin,mhowell,sgalich,alwu
Sorry this is not a particularly easy patch to review. But it should be
mostly straight-forward.

I kept Document::Dispatch mostly for convenience, but could be
cleaned-up too / changed by SchedulerGroup::Dispatch. Similarly maybe
that can just be NS_DispatchToMainThread if we add an NS_IsMainThread
check there or something (to preserve shutdown semantics).

Differential Revision: https://phabricator.services.mozilla.com/D190450
2023-10-10 08:51:12 +00:00
Jan Varga
272327b326 Bug 1855134 - Move existing MOZ_TRY macros to a dedicated header file; r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D189226
2023-09-28 20:46:07 +00:00
serge-sans-paille
59eeffffb2 Bug 1854478 - Improve constness of array of preferences r=KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D188884
2023-09-28 15:04:00 +00:00
Masatoshi Kimura
e740f7ed25 Bug 1850247 - Add pref name to warning log. r=KrisWright
I could not have found the regressor without this.

Differential Revision: https://phabricator.services.mozilla.com/D186884
2023-08-31 16:58:12 +00:00
Stephen A Pohl
4593f6726f Bug 1815471: Remove support for special pref files. r=mkaply,KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D169082
2023-08-02 15:54:03 +00:00
Morgan Rae Reschenberg
efd4377b63 Bug 1844213: Add accessibility.tabfocus to the dynamic pref override list r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D184030
2023-07-24 19:42:45 +00:00
Tom Schuster
2454d6dc41 Bug 1843841 - Make navigator.appName constant. r=dom-worker-reviewers,webidl,smaug,timhuang
This is supposed to constant per https://html.spec.whatwg.org/#client-identification.

Differential Revision: https://phabricator.services.mozilla.com/D183723
2023-07-19 17:00:53 +00:00
Sebastian Hengst
e2750a2917 Bug 1843197 - add some services.* prefs as not to be sanitized, as intended. r=tjr
The services.* preferences branch gets sanitizer by default. Exceptions
need to be added in the ShouldSanitizePreference method.

services.settings.loglevel got added in bug 1840851.
services.settings.preview_enabled got added in bug 1780403.

Differential Revision: https://phabricator.services.mozilla.com/D183442
2023-07-14 12:44:44 +00:00
Tom Ritter
fdaf0cff33 Bug 1840851: Add a few prefs to the allowlist r=freddyb
Differential Revision: https://phabricator.services.mozilla.com/D182359
2023-06-30 13:48:54 +00:00
Marco Castelluccio
8093b2706a Bug 720419 - Remove nsIPrefBranch::ResetBranch. r=KrisWright
Make it so callers need to explicitly iterate through prefs using getChildList
when they want to reset an entire branch, to avoid the footgun of resetting
unintended prefs when using resetBranch for clearing a single pref.
See also https://phabricator.services.mozilla.com/D11381#357618.

Differential Revision: https://phabricator.services.mozilla.com/D180548
2023-06-12 18:01:25 +00:00
Mike Hommey
71e957fead Bug 1833676 - Disable thread safety analysis on InitStaticPrefsFromShared. r=KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D178403
2023-05-23 21:55:25 +00:00
nicklas boman
4114a8d7f7 Bug 1724649 - Followup to remove #include plstr.h r=necko-reviewers,xpcom-reviewers,valentin,nika
Differential Revision: https://phabricator.services.mozilla.com/D177690
2023-05-15 14:53:02 +00:00
Daniel Holbert
101cfcaffe Bug 1826268: Use StaticAutoPtr to manage several global variables in Preferences.cpp. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D174558
2023-04-05 20:41:17 +00:00
Daniel Holbert
010aeffcca Bug 1826234: Fix GetObserverService error-handling check in Preferences::InitInitialObjects. r=xpcom-reviewers,emilio
In mozilla-central before this patch, we had a boilerplate
NS_ENSURE_SUCCESS(rv, rv) after our call to GetObserverService()

This expression *does not actually test whether GetObserverService() succeeded*
though, since GetObserverService doesn't touch rv!  When GetObserverService()
fails, it just returns nullptr.  So we should be testing it for success with a
null-check.

In fact, we did *used to* test for success with a null-check, but that was
replaced by this ineffective NS_ENSURE_SUCCESS by accident in Bug 1276488, as
part of a large patch that was geared at adding diagnostics.

So: let's just restore the null-check. It's unlikely to be tripped, since
GetObserverService only returns nullptr at xpcom shutdown time (and this code
runs at startup); but explicitly handling that by returning a failure code
seems to be the right thing to do.  And more importantly, the NS_ENSURE_SUCCESS
can be made to misfire if we happen to have a stray error code from some
earlier call remaining in 'rv'.

Differential Revision: https://phabricator.services.mozilla.com/D174544
2023-04-04 01:06:01 +00:00
Lata
0b8f41c034 Bug 1823612 - Remove usage of marionette.log.level from Log.sys.mjs. r=whimboo,webdriver-reviewers,perftest-reviewers,sparky
Differential Revision: https://phabricator.services.mozilla.com/D173207
2023-03-29 15:21:16 +00:00
Andi-Bogdan Postelnicu
011e3fc2d9 Bug 1660405 - Move away from mozilla::IsNaN in favor of std::isnan. r=nbp,media-playback-reviewers,sergesanspaille,padenot
Differential Revision: https://phabricator.services.mozilla.com/D173035
2023-03-22 11:35:33 +00:00
Stanca Serban
98c675ed3f Backed out 7 changesets (bug 1660405) for causing bustages on Linux x64 opt. CLOSED TREE
Backed out changeset ad1a5f59214f (bug 1660405)
Backed out changeset a39e95f0aafe (bug 1660405)
Backed out changeset 48629ee0d70d (bug 1660405)
Backed out changeset 8419b99aab60 (bug 1660405)
Backed out changeset 535cc12c8bed (bug 1660405)
Backed out changeset e27052da4927 (bug 1660405)
Backed out changeset 11b0f9cf8091 (bug 1660405)
2023-03-22 13:05:53 +02:00
Andi-Bogdan Postelnicu
5e0156c1e4 Bug 1660405 - Move away from mozilla::IsNaN in favor of std::isnan. r=nbp,media-playback-reviewers,sergesanspaille,padenot
Differential Revision: https://phabricator.services.mozilla.com/D173035
2023-03-22 09:27:56 +00:00
Tom Ritter
80af8b4848 Bug 1815893: Add three more preferences to the allowlist r=freddyb
Depends on D171763

Differential Revision: https://phabricator.services.mozilla.com/D171767
2023-03-07 15:15:31 +00:00
Florian Quèze
411879f425 Bug 1817297 - Stop sending PreferenceUpdate IPC messages for sanitized preferences, r=florian,KrisWright
Differential Revision: https://phabricator.services.mozilla.com/D170115
2023-03-06 15:21:36 +00:00
Jan Horak
939151647f Bug 1170092 Load preferences from /etc/firefox/defaults/pref on Linux; r=mkaply
Preferences from /etc/firefox/defaults/pref overwrites preferences set in omni.jar
and firefox/defaults/pref. The code was used for flatpak and snap only, but it could
be used also for regular Linux builds.

Differential Revision: https://phabricator.services.mozilla.com/D168799
2023-03-02 14:41:56 +00:00
serge-sans-paille
179f18d76b Bug 1819821 - Make modules/libpref buildable outside of a unified build environment r=andi
Depends on D171427

Differential Revision: https://phabricator.services.mozilla.com/D171428
2023-03-02 07:44:31 +00:00
Marian-Vasile Laza
b852b334b6 Backed out changeset d0d2fe421be4 (bug 1170092) for xpcshell failures on /test_autoconfig_custom_path.js. CLOSED TREE 2023-02-21 18:45:03 +02:00
Jan Horak
9abda37aa1 Bug 1170092 Load preferences from /etc/firefox/defaults/pref on Linux; r=mkaply
Preferences from /etc/firefox/defaults/pref overwrites preferences set in omni.jar
and firefox/defaults/pref. The code was used for flatpak and snap only, but it could
be used also for regular Linux builds.

Differential Revision: https://phabricator.services.mozilla.com/D168799
2023-02-21 14:12:42 +00:00
Florian Quèze
693c4e0871 Bug 1815438 - add Preference Write markers, r=canaltinova.
Depends on D169239

Differential Revision: https://phabricator.services.mozilla.com/D169240
2023-02-10 21:50:03 +00:00
Florian Quèze
9ea49c1f01 Bug 1815438 - remove the 'Preference Read' profiler feature and record these markers unconditionally, r=canaltinova.
Differential Revision: https://phabricator.services.mozilla.com/D169239
2023-02-10 21:50:02 +00:00
Tom Ritter
61e8321014 Bug 1815893: Allowlist two internationalization custom preferences r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D169499
2023-02-10 19:12:02 +00:00
Tom Ritter
0e776d7faf Bug 1811294: Roll out Pref Sanitization r=smaug
1. Ship the Sanitization (currently on in Nightly
     but without crashing) to the trains
2. Enabling crashing in Nightly

#1 will start omitting the preference values in
Content Processes. An affected user will have
their browser behave differently - it will be as
if the preference has no value. So for e.g. the
font preferences, their font customizations will
be gone. If they file a bug about this happening
and an engineer connects the problem to pref
sanitization we could debug the issue and maybe
understand it.

#2 will mean that an affected user (of which
there are currently none we think) will have a
content process crash when they access a
forbidden preference. The crash reason will
contain the name of the preference, and the
stack which would help us better understand
why we crashed.

Differential Revision: https://phabricator.services.mozilla.com/D167287
2023-02-06 19:15:23 +00:00
Daisuke Akatsuka
72aca246e7 Bug 1725045: Remove browser.urlbar.resultGroups pref. r=adw
Differential Revision: https://phabricator.services.mozilla.com/D167889
2023-01-26 23:10:19 +00:00
Artur Iunusov
0c3dca4f67 Bug 1671548 - Remove fission experiment support code and prefs, r=smaug,
r=tritter

- backed out changesets: 1660057, 1667426, 1674214,
1669749, 1685801, 1667381
- fission.experiment support removed everywhere, including telemetry

Differential Revision: https://phabricator.services.mozilla.com/D165169
2023-01-17 10:05:36 +00:00
Florian Quèze
acbadad33e Bug 1803543 - Improve the PreferenceRead marker schema to make the marker table show the name and value of the preferences, r=canaltinova.
Differential Revision: https://phabricator.services.mozilla.com/D163581
2022-12-19 18:01:14 +00:00
Nazım Can Altınova
c91a8714b7 Bug 1803751 - Make some marker fields searchable and bump the profile version r=julienw
Differential Revision: https://phabricator.services.mozilla.com/D163714
2022-12-13 14:19:07 +00:00
Iulian Moraru
94985653c4 Backed out changeset 27f8690ebc50 (bug 1803751) for causing xpcshell failures on test_feature_mainthreadio.js. CLOSED TREE 2022-12-12 17:43:23 +02:00
Nazım Can Altınova
76eaba45b7 Bug 1803751 - Make some marker fields searchable and bump the profile version r=julienw
Differential Revision: https://phabricator.services.mozilla.com/D163714
2022-12-12 13:11:56 +00:00
Nika Layzell
c0cbc0f82e Bug 840706 - Part 3: Restore old float-parsing behaviour for preferences, r=KrisWright
These can be set by users, and callers often don't do a great job of
handling errors, so maintaining the existing error behaviour is our
safest option here. In addition, there are some tests which set prefs to
very large values, resulting in `inf` being used as the returned
preference value.

In the future it may be nice to make the error handling behaviour act
more consistently with other branches (not clobbering the outparam on
error), though that was left out from this change.

Differential Revision: https://phabricator.services.mozilla.com/D148306
2022-12-06 20:27:50 +00:00
Tom Ritter
6216467e31 Bug 1804097: Generalize the allowlist for network.security.ports.banned r=ckerschb
Differential Revision: https://phabricator.services.mozilla.com/D163851
2022-12-06 16:40:41 +00:00
Tom Ritter
375a98344c Bug 1801711: Allowlist some additional prefs for the content processes r=freddyb
Differential Revision: https://phabricator.services.mozilla.com/D162595
2022-11-22 15:25:10 +00:00
Tom Ritter
4f27698bf7 Bug 1796196: Do not sanitize preferences destined for Privileged About Processes r=nika,KrisWright
- Do not allow preallocated processed to turn into Privileged
  About Content Processes
- Separate ShouldSanitizePreference into a more logical
  'ShouldSanitizePreference' to use when sending a process to
  a subprocess, and a separate IsPreferenceSanitized to be used
  when accessing a preference
- Remove several now-redundant parts of conditionals like
  - gContentProcessPrefsAreInited (now inside IsPreferenceSanitized)
  - !XRE_IsParentProcess() (now inherent in the check)
- Remove the aIsDestinationWebContentProcess argument - it's not
  needed in IsPreferenceSanitized, and can be checked outside
  ShouldSanitizePreference

  The original (partial) preference omitting code was done for
  performance, and stuck around partially in the sanitization code -
  preferences explicitly blocklisted were omitted from all
  sub-processes. But those preferences changed from large preferences
  to privacy-sensitive ones and with this change we no longer omit
  any preferences from all sub-processes, we only sanitize some
  preferences for web content processes.

  We could bring back this performance behavior though, and tailor
  it specifically for performance and not privacy.

Differential Revision: https://phabricator.services.mozilla.com/D159940
2022-11-03 18:55:11 +00:00
Botond Ballo
877404eab3 Bug 1798063 - Allowlist the apz.subtest pref. r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D160877
2022-11-01 17:39:44 +00:00
Tom Ritter
2af123ff6a Bug 1791814: Address two preferences showing up in telemetry r=freddyb
Differential Revision: https://phabricator.services.mozilla.com/D158989
2022-10-19 01:39:35 +00:00
Alexandre Lissy
ffdd6fb20f Bug 1785278 - Reading AutoConfig from /etc/firefox when running under Snap r=mkaply,xpcom-reviewers,barret
Differential Revision: https://phabricator.services.mozilla.com/D159059
2022-10-18 21:06:43 +00:00