Commit Graph

4450 Commits

Author SHA1 Message Date
Christian Holler (:decoder)
b48efc60ec Bug 1833351 - Handle invalid URI to nsIconChannel gracefully. r=jld
Differential Revision: https://phabricator.services.mozilla.com/D178158
2023-05-25 22:58:59 +00:00
Emilio Cobos Álvarez
7d479f6a4a Bug 1832528 - Make cors mode part of the image cache key. r=tnikkel
So that we can hold entries loaded with different CORS modes, such as
masks and backgrounds.

Differential Revision: https://phabricator.services.mozilla.com/D177759
2023-05-25 22:25:31 +00:00
Otto Länd
43499f6fab Bug 1703812, 1817997, 1821362: apply code formatting via Lando
# ignore-this-changeset
2023-05-24 13:28:38 +00:00
Paul Adenot
a9bfcf37e3 Bug 1817997 - Update nsAVIFDecoder to use the new mp4parse-rust time units. r=kinetik
Differential Revision: https://phabricator.services.mozilla.com/D176048
2023-05-24 13:18:44 +00:00
Paul Adenot
20b2262251 Bug 1817997 - Adjust code to take advantage of the new TimeUnit API. r=alwu
Differential Revision: https://phabricator.services.mozilla.com/D171256
2023-05-24 13:18:39 +00:00
Natalia Csoregi
e87ecf485e Backed out 3 changesets (bug 1834222, bug 1834176) for causing RemoteProcessMonitor failures. CLOSED TREE
Backed out changeset 346d3a1568dd (bug 1834222)
Backed out changeset ea1d8b634bfc (bug 1834176)
Backed out changeset 74d1880272d3 (bug 1834176)
2023-05-24 04:29:45 +03:00
Mark Banner
fbc15bdb60 Bug 1834176 - Convert NetUtil.jsm to be an ES system module. r=arai,webdriver-reviewers,perftest-reviewers,valentin,extension-reviewers,devtools-reviewers,sync-reviewers,cookie-reviewers,robwu,afinder,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D178589
2023-05-23 19:09:29 +00:00
Noemi Erli
aa2f146d78 Backed out 2 changesets (bug 1834176) for causing xpc failures in test_unload.js CLOSED TREE
Backed out changeset 57876d77a652 (bug 1834176)
Backed out changeset ae2f0837b528 (bug 1834176)
2023-05-23 12:14:37 +03:00
Mark Banner
e3e9a991b8 Bug 1834176 - Convert NetUtil.jsm to be an ES system module. r=arai,webdriver-reviewers,perftest-reviewers,valentin,extension-reviewers,devtools-reviewers,sync-reviewers,cookie-reviewers,robwu,afinder,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D178589
2023-05-23 08:13:08 +00:00
Mark Banner
130a655906 Bug 1826062 - Automatic fixes for upgrading Prettier to 2.8.8. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,calu
Differential Revision: https://phabricator.services.mozilla.com/D177027
2023-05-20 12:26:53 +00:00
Mark Banner
8219a5c503 Bug 1826062 - Automatic fixes for Prettier 2.0.5 upgrade. r=mossop,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,denschub,devtools-reviewers,sparky,owlish
Differential Revision: https://phabricator.services.mozilla.com/D177025
2023-05-20 12:26:49 +00:00
Cosmin Sabou
5fd965f028 Backed out 80 changesets (bug 1821362, bug 1703812, bug 1817997) for causing media crashes as in Bug 1833890. a=backout
Backed out changeset f2113c9b661f (bug 1817997)
Backed out changeset f1ecfbba7ed2 (bug 1703812)
Backed out changeset 011cece33b0d (bug 1817997)
Backed out changeset 4b42659090f3 (bug 1817997)
Backed out changeset 2d92f903dd66 (bug 1817997)
Backed out changeset 0ef13d357ee3 (bug 1817997)
Backed out changeset 7353f869efd2 (bug 1703812)
Backed out changeset 14b061d0f595 (bug 1817997)
Backed out changeset d29bc29397c8 (bug 1703812)
Backed out changeset 54c3294f0839 (bug 1817997)
Backed out changeset b9f2e1155bd7 (bug 1817997)
Backed out changeset d5d5d390dcbf (bug 1817997)
Backed out changeset 8fca27bd0f6b (bug 1817997)
Backed out changeset 670c599a3b99 (bug 1817997)
Backed out changeset deea3077f762 (bug 1817997)
Backed out changeset 25ecea0f3d49 (bug 1817997)
Backed out changeset 35ab3ed5e3fc (bug 1817997)
Backed out changeset f516a428ba32 (bug 1817997)
Backed out changeset e589b4d30995 (bug 1817997)
Backed out changeset d096b9cc905d (bug 1817997)
Backed out changeset 2952a6fa06e5 (bug 1817997)
Backed out changeset c1ac4c31ad9a (bug 1817997)
Backed out changeset 04c60cd83c5f (bug 1821362)
Backed out changeset 6dd80575e551 (bug 1821362)
Backed out changeset b86b569ecd46 (bug 1817997)
Backed out changeset 412e0a9ec4e8 (bug 1817997)
Backed out changeset 8e0dcf163138 (bug 1817997)
Backed out changeset 7af506896930 (bug 1817997)
Backed out changeset 29f7cd2b341c (bug 1817997)
Backed out changeset 7f64e65d9497 (bug 1817997)
Backed out changeset 89c241451a32 (bug 1817997)
Backed out changeset 66e4a26e1ebe (bug 1817997)
Backed out changeset ea1aebd4e245 (bug 1817997)
Backed out changeset 2d88a5915db9 (bug 1817997)
Backed out changeset 697ec1928f9c (bug 1817997)
Backed out changeset 41c0bd1133c5 (bug 1817997)
Backed out changeset b20cc750c020 (bug 1817997)
Backed out changeset dc5fd84a3a4c (bug 1703812)
Backed out changeset efa6d130d4eb (bug 1703812)
Backed out changeset 20d9b7cf0ddc (bug 1703812)
Backed out changeset e77c61e8fad2 (bug 1703812)
Backed out changeset 582d5c680e5a (bug 1703812)
Backed out changeset 96c9aacc6811 (bug 1703812)
Backed out changeset 56ec4a57a6a6 (bug 1703812)
Backed out changeset 8f96c8811675 (bug 1703812)
Backed out changeset a79a2f1b2b51 (bug 1703812)
Backed out changeset 07eb8b2c5b9f (bug 1703812)
Backed out changeset bae2b2fb9759 (bug 1703812)
Backed out changeset 38b0416538f3 (bug 1703812)
Backed out changeset b27b54c95cf2 (bug 1703812)
Backed out changeset cab00065d83d (bug 1703812)
Backed out changeset ab44727b2e1a (bug 1703812)
Backed out changeset b7fdcb494670 (bug 1703812)
Backed out changeset 73db43d49c6d (bug 1703812)
Backed out changeset ce754dbfb862 (bug 1703812)
Backed out changeset d694726a3ee6 (bug 1703812)
Backed out changeset 6acede55acbb (bug 1703812)
Backed out changeset 86e7d4784a20 (bug 1703812)
Backed out changeset 6b2e055d9314 (bug 1703812)
Backed out changeset b08695e5728a (bug 1703812)
Backed out changeset 3b8a0081fd10 (bug 1703812)
Backed out changeset 3a163596f982 (bug 1703812)
Backed out changeset 5be1d4b282ab (bug 1703812)
Backed out changeset 1ce012d7509e (bug 1703812)
Backed out changeset ee2fab5881c7 (bug 1703812)
Backed out changeset 62941a522893 (bug 1703812)
Backed out changeset d4f11dc33eed (bug 1703812)
Backed out changeset 781bb4c3cc02 (bug 1703812)
Backed out changeset f070e0de0566 (bug 1703812)
Backed out changeset 9f65c67ba2a6 (bug 1703812)
Backed out changeset 1e76eecb85e2 (bug 1703812)
Backed out changeset 953432408a83 (bug 1703812)
Backed out changeset fd1dc92d3911 (bug 1703812)
Backed out changeset 34d56948c6b6 (bug 1703812)
Backed out changeset 2ba7ca61ecc3 (bug 1703812)
Backed out changeset 545253c469e6 (bug 1703812)
Backed out changeset fb4a61ab1300 (bug 1703812)
Backed out changeset bf07b3cfd3d5 (bug 1703812)
Backed out changeset eaff51e7754b (bug 1703812)
Backed out changeset f5c485c41d13 (bug 1703812)
2023-05-19 14:49:57 +03:00
Sean Feng
bd1e35c1d2 Bug 1816287 - Always exit fullscreen when triggering on external protocol r=edgar
It's a security risk such that the maximized external program can obscure
the fullscreen notification and the malicious site can use this trick
to load a spoofed page in the background without user notices it.

This patch minimized the risk by always exit the fullscreen mode when
an external protocol is triggered.

Differential Revision: https://phabricator.services.mozilla.com/D177771
2023-05-17 18:00:18 +00:00
Norisz Fay
34b6c94a76 Backed out changeset 6fa00ccfe7e0 (bug 1816287) for causing bustages on LocationBase.cpp CLOSED TREE 2023-05-17 20:11:39 +03:00
Sean Feng
9740581cf7 Bug 1816287 - Always exit fullscreen when triggering on external protocol r=edgar
It's a security risk such that the maximized external program can obscure
the fullscreen notification and the malicious site can use this trick
to load a spoofed page in the background without user notices it.

This patch minimized the risk by always exit the fullscreen mode when
an external protocol is triggered.

Differential Revision: https://phabricator.services.mozilla.com/D177771
2023-05-17 16:34:57 +00:00
Otto Länd
73f06050fb Bug 1703812, 1817997, 1821362: apply code formatting via Lando
# ignore-this-changeset
2023-05-17 16:00:46 +00:00
Paul Adenot
9925667f68 Bug 1817997 - Update nsAVIFDecoder to use the new mp4parse-rust time units. r=kinetik
Differential Revision: https://phabricator.services.mozilla.com/D176048
2023-05-17 15:47:08 +00:00
Paul Adenot
0aeade5787 Bug 1817997 - Adjust code to take advantage of the new TimeUnit API. r=alwu
Differential Revision: https://phabricator.services.mozilla.com/D171256
2023-05-17 15:47:03 +00:00
nicklas boman
5e31225558 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
Emilio Cobos Álvarez
6d294944a6 Bug 1832553 - Remove the chrome / non-chrome image cache split. r=tnikkel
This probably made more sense when everything was in the same process,
so that prefs like the image cache size etc only measured web content.

But that's achieved via e10s nowadays, so probably having different
cache tables for chrome:// URIs is overkill. Plus, we probably want to
also clear resource:// URIs etc when flushing chrome caches and so on.

Differential Revision: https://phabricator.services.mozilla.com/D177765
2023-05-13 08:31:46 +00:00
Kershaw Chang
8f95e3fca6 Bug 1808323 - Add telemetry for the page load time and the time to first paint for sites that supports Early Hints response, r=manuel,necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D165966
2023-05-02 08:08:44 +00:00
Timothy Nikkel
9d0226a146 Bug 1823375. Fix all variable shadowing warnings in imagelib. r=Zaggy1024,gfx-reviewers,nical
We can't actually enable the warning because there are some warnings generated by includes coming from outside of imagelib.

Note that change in AOMDecoder::Init is actually a behaviour change: the new behaviour is to return the error code if we fail to decode the alpha image. This matches what we do for the dav1d decoder.

Depends on D173000

Differential Revision: https://phabricator.services.mozilla.com/D173001
2023-04-11 08:06:29 +00:00
Nika Layzell
d57c9498f6 Bug 1825360 - Remove the NS_DISPATCH_SYNC flag, r=necko-reviewers,geckoview-reviewers,media-playback-reviewers,karlt,jesup,m_kato,emilio
This flag is not supported by most event targets and can have unexpected
side effects (namely spinning a nested event loop). All consumers have
been replaced with a new function which is more explicit about this side
effect.

Differential Revision: https://phabricator.services.mozilla.com/D173985
2023-03-30 16:53:51 +00:00
Otto Länd
314123012b Bug 1276351: apply code formatting via Lando
# ignore-this-changeset
2023-03-27 07:23:36 +00:00
Andi-Bogdan Postelnicu
4efa1bd0ba Bug 1276351 - Move away from mozilla::tuple to std::tuple. r=necko-reviewers,sergesanspaille
Differential Revision: https://phabricator.services.mozilla.com/D173256
2023-03-27 07:20:25 +00:00
Sandor Molnar
9db345d4c1 Backed out 2 changesets (bug 1276351) for causing build bustage in image/ClippedImage.cp CLOSED TREE
Backed out changeset e84598eb82c1 (bug 1276351)
Backed out changeset e940b0554484 (bug 1276351)
2023-03-25 14:16:43 +02:00
Andi-Bogdan Postelnicu
447f1e3358 Bug 1276351 - Move away from mozilla::tuple to std::tuple. r=necko-reviewers,sergesanspaille
Differential Revision: https://phabricator.services.mozilla.com/D173256
2023-03-25 06:58:52 +00:00
Timothy Nikkel
2f85ec68a3 Bug 1823614. Limit the number of scans we allow in jpeg images to some finite value. r=gfx-reviewers,bradwerth a=reland
We want to provide some finite limit to prevent small jpeg files from being able to tie up cpus for a much larger time than their small size would normally allow. We want to choose a number high enough so that no sane jpeg file would approach it, unless it had been crafted to take advantage of this problem.

Skia's jpeg decoder limit's it to 100:

https://searchfox.org/mozilla-central/rev/f078cd02746b29652c134b144f0629d47e378166/gfx/skia/skia/src/codec/SkJpegDecoderMgr.cpp#33

The OSS_Fuzz targets for libjpeg-turbo limit it to 500:

https://bugzilla.mozilla.org/show_bug.cgi?id=1252196#c11

Differential Revision: https://phabricator.services.mozilla.com/D173120
2023-03-25 01:46:53 +00:00
Iulian Moraru
0b75230e48 Backed out changeset 9e5254e7728e (bug 1823614) for causing reftest failures on pattern-transformed. CLOSED TREE 2023-03-25 05:23:27 +02:00
Timothy Nikkel
6a90e1f8f5 Bug 1823614. Limit the number of scans we allow in jpeg images to some finite value. r=gfx-reviewers,bradwerth
We want to provide some finite limit to prevent small jpeg files from being able to tie up cpus for a much larger time than their small size would normally allow. We want to choose a number high enough so that no sane jpeg file would approach it, unless it had been crafted to take advantage of this problem.

Skia's jpeg decoder limit's it to 100:

https://searchfox.org/mozilla-central/rev/f078cd02746b29652c134b144f0629d47e378166/gfx/skia/skia/src/codec/SkJpegDecoderMgr.cpp#33

The OSS_Fuzz targets for libjpeg-turbo limit it to 500:

https://bugzilla.mozilla.org/show_bug.cgi?id=1252196#c11

Differential Revision: https://phabricator.services.mozilla.com/D173120
2023-03-25 01:46:53 +00:00
Iulian Moraru
6d40eee997 Backed out 2 changesets (bug 1276351) for causing multiple failures.
Backed out changeset eeaf4f1e06af (bug 1276351)
Backed out changeset d44cb5704342 (bug 1276351)
2023-03-25 00:08:24 +02:00
Andi-Bogdan Postelnicu
a1b827b503 Bug 1276351 - Move away from mozilla::tuple to std::tuple. r=necko-reviewers,sergesanspaille
Differential Revision: https://phabricator.services.mozilla.com/D173256
2023-03-24 18:55:39 +00:00
Timothy Nikkel
57ebc1d81a Bug 1277397. Set a max memory limit for libjpeg turbo to use. r=gfx-reviewers,bradwerth
This means that for trivial images whose header specifies large dimensions but with no image data  we don't use a lot of memory.

Differential Revision: https://phabricator.services.mozilla.com/D173119
2023-03-24 04:47:43 +00:00
Timothy Nikkel
3fb8b06877 Bug 1818725. Don't ignore the return value of nsAVIFDecoder::CreateDecoder. r=Zaggy1024
And also make it return a better result when mDecoder already exists, Complete is not what we want to return.

Depends on D172994

Differential Revision: https://phabricator.services.mozilla.com/D172998
2023-03-23 03:39:06 +00:00
Tom Schuster
1509ba1c86 Bug 1808146 - When creating a file promise for images, remember the referrer. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D172920
2023-03-22 21:55:08 +00:00
Kershaw Chang
5e58575e28 Bug 1809843 - Skip Failed tests, r=necko-reviewers,extension-reviewers,credential-management-reviewers,valentin,sgalich,robwu
Differential Revision: https://phabricator.services.mozilla.com/D171842
2023-03-21 09:09:58 +00:00
Timothy Nikkel
c869e31d5e Bug 1818724. Rename nsAVIFDecoder::Decode. r=Zaggy1024
Because it has the same name as the base class function Decoder::Decode but different arguments, which is confusing.

Depends on D172998

Differential Revision: https://phabricator.services.mozilla.com/D173000
2023-03-20 23:46:50 +00:00
Timothy Nikkel
2c69c06d89 Bug 1813562. Fix leak with color profile and transform in avif decoder. r=Zaggy1024
We run this code for every frame of animated images, so we need to make the code handle that.

Differential Revision: https://phabricator.services.mozilla.com/D172994
2023-03-20 22:49:39 +00:00
zaggy1024
ef5aaf44a9 Bug 1813466 - Store AVIF prefs as default decoder flags in RasterImage. r=tnikkel
This prevents a crash that would occur if a redecode of an animated AVIF happened after changing the `sequences.enabled` pref from `true` to `false`.

Differential Revision: https://phabricator.services.mozilla.com/D170190
2023-03-17 00:50:07 +00:00
Nika Layzell
3b40268cc1 Bug 1818305 - Part 2: Add a streamStatus method to nsIInputStream, r=xpcom-reviewers,necko-reviewers,geckoview-reviewers,valentin,jesup,m_kato,mccr8
This is semantically similar to the existing available() method, however will
not block, and doesn't need to do the work to actually determine the number of
available bytes.

As part of this patch, I also fixed one available() implementation which was
incorrectly throwing NS_BASE_STREAM_WOULD_BLOCK.

Differential Revision: https://phabricator.services.mozilla.com/D170697
2023-03-15 19:52:34 +00:00
Marian-Vasile Laza
ee72efd1e9 Backed out 5 changesets (bug 1809843) for causing Cargo related build bustages. CLOSED TREE
Backed out changeset 5c494680f448 (bug 1809843)
Backed out changeset 02742b38edab (bug 1809843)
Backed out changeset 2b9b32ca8294 (bug 1809843)
Backed out changeset 56631cb02ae6 (bug 1809843)
Backed out changeset 37e35a60a71f (bug 1809843)
2023-03-13 13:53:26 +02:00
Kershaw Chang
a60df34ad0 Bug 1809843 - Skip Failed tests, r=necko-reviewers,extension-reviewers,credential-management-reviewers,valentin,sgalich,robwu
Differential Revision: https://phabricator.services.mozilla.com/D171842
2023-03-13 11:12:33 +00:00
Timothy Nikkel
379fa32eff Bug 1818903. Adjust fuzz on moz-icon reftest for Windows 11. r=emilio
I looked at the failures compared to the passing results. The passing results look very faint and blurry. The failures look much better actually.

Differential Revision: https://phabricator.services.mozilla.com/D171552
2023-03-03 12:17:21 +00:00
zaggy1024
e349b686f8 Bug 1817108 - Check that AVIF frame sizes remain unchanged during animation. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D170193
2023-03-01 07:04:31 +00:00
Brad Werth
75eeec6a99 Bug 1768495 Part 4: Disable window occlusion tracker pref on crashtests that rely on a running compositor. r=emilio
These crashtests rely upon either a requestAnimationFrame callback or a
MozAfterPaint event. Those currently won't happen when the compositor is
paused, and on Windows these crashtests are occluded, which will now pause
the compositor. To deal with this, we disable the occlusion tracking pref
on Windows. Other platforms seem not to treat the crashtests as occluded,
so their compositors keep running.

Differential Revision: https://phabricator.services.mozilla.com/D171137
2023-02-28 23:04:54 +00:00
Jonathan Kew
4594ae314a Bug 1815404 - Replace most uses of gfxContext::CreateOrNull with stack-allocated contexts. r=gfx-reviewers,lsalzman
Depends on D170370

Differential Revision: https://phabricator.services.mozilla.com/D170371
2023-02-21 07:28:25 +00:00
Jonathan Kew
1b3e69f8aa Bug 1815404 - Remove refcounting from gfxContext. r=gfx-reviewers,lsalzman
Depends on D170367

Differential Revision: https://phabricator.services.mozilla.com/D170369
2023-02-21 07:28:24 +00:00
Tyson Smith
f14d70cf52 Bug 1817479 - Enable AVIF sequence support in DecodeToSurface Fuzzer. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D170230
2023-02-18 04:19:54 +00:00
Gijs Kruitbosch
387cf24ca0 Bug 1810141 - fix tests to deal with changes to loadURI, r=mossop,perftest-reviewers,geckoview-reviewers,extension-reviewers,sparky,owlish
Depends on D168396

Differential Revision: https://phabricator.services.mozilla.com/D168397
2023-02-13 23:50:41 +00:00
Andi-Bogdan Postelnicu
d7e8a09c21 Bug 1519636 - Reformat recent changes to the Google coding style. r=glandium
Updated with clang-format version 15.0.5 (taskcluster-MKK8dHUpQkGfPLA793lizg)
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D168658
2023-02-13 15:02:07 +00:00