Previously this was allowed only in content processes, but we've gained
other process types over the years, and it's possible for libc realloc's
mremap case to be reached in any process type (if less common in practice).
This restricts the flags argument to contain at most `MREMAP_MAYMOVE`, to
allow what dlmalloc descendants (glibc, bionic) use for `realloc`.
Note that this does not affect normal builds, only ones which opt out
of our own malloc implemtnation, typically in order to use some kind of
memory instrumentation like valgrind.
Differential Revision: https://phabricator.services.mozilla.com/D192028
This patch updates libvpx by two steps:
1. ./mach vendor media/libvpx/moz.yaml --patch-mode=none
2. ./mach vendor media/libvpx/moz.yaml --patch-mode=only
The first step pulls the upstream repo files to gecko, and the second
step applies the local patches.
Differential Revision: https://phabricator.services.mozilla.com/D192108
This modifies tests to use the server. There are a few important points to call
out:
This means tests are now using the real Rust component, and we need to make sure
the test RS data is valid and matches what Rust expects. For example, I had to
add `icon` properties to suggestions and set the `advertiser` to "Wikipedia" for
non-sponsored suggestions. Otherwise Rust hits an error on ingest. I also
removed some test cases because they tested behaviors that are impossible with
Rust, for example Pocket keywords that are duplicated in the high- and
low-confidence arrays.
We need to be careful to wait until Suggest is done syncing from remote settings
regardless of whether it's using the JS or Rust backend. I added a way to force
the backends to sync. That way, tests can force a sync, wait for it to finish,
and be sure that all sync activity is done.
A common pattern in tests is to call `ensureQuickSuggestInit()` and then set
Suggest-related prefs (or vice versa). This is a little problematic because both
`ensureQuickSuggestInit()` and setting prefs can cause Suggest to start a sync.
It's more problematic now that we're not mocking remote settings or Rust. So I
combined the two by adding a `prefs` param to `ensureQuickSuggestInit()`. That
way, tests can be sure that all syncing is done once that function returns.
Depends on D192037, D192124
Differential Revision: https://phabricator.services.mozilla.com/D192038
This implements a remote settings server for tests. Unfortunately there doesn't
seem to be a general-purpose implementation already in the tree.
In part 2, I'll update tests so they use it.
Differential Revision: https://phabricator.services.mozilla.com/D192037
Despite having passed through test-verify cleanly, the crash test is
still sometimes failing due to a dump not being generated.
Increase it to one full second, to give the file dialog time to open. If
this doesn't suffice we'll have to either add another flavor of promise
in the test-only code, or disable the test entirely.
Differential Revision: https://phabricator.services.mozilla.com/D192101
This makes sure `result.payload.originalUrl` is set correctly depending on Rust
vs. JS, and AMP vs. Wikipedia. The logic is getting a little messy due to all
the various combinations, but there's no way around it until we drop the JS
backend.
I tried setting `raw_url` (or `rawUrl`) on JS suggestions to match Rust
suggestions, and while that made the `AdmWikipedia` logic slightly nicer, it
either made the `UrlbarProviderQuickSuggest._canAddSuggestion()` logic a little
uglier because we need to also check `raw_url` for JS suggestions (snake_case),
or instead we could set `rawUrl` (camelCase) on JS suggestions just like Rust
suggestions, but every other property on JS suggestions uses snake_case.
This is *not* based on bug 1861540 because we need to uplift this, but I don't
want to uplift bug 1861540.
Differential Revision: https://phabricator.services.mozilla.com/D192124
Because the break-after/break-before should cause the new page name to be on
the next page, there should only be one page-break.
One of these cases is still not solved, but the simple case works now.
Differential Revision: https://phabricator.services.mozilla.com/D191711
Add the protocol buffer and client side of the SDK to the Gecko build. This includes prefs to enable/disable/configure content analysis. In addition to the pref, content analysis requires a command-line argument "-allow-content-analysis" to be turned on; this is for security reasons until we make sure that the pref can only be turned on by enterprise policies.
Differential Revision: https://phabricator.services.mozilla.com/D189568