Commit Graph

14536 Commits

Author SHA1 Message Date
Bryce Van Dyk
6de97a2168 Bug 1525646 - Add debug logging to MoofParser. r=jya
The MoofParser didn't have logging on its normal code paths. This patch
implements such logging, covering entry and exit to many functions. Such verbose
logs are helpful for diagnosing failures and the specific file structure leading
to such failures. This should help improve our debugging experience if we can
get logs from end users which is particularly useful for cases where they can't
provide us with media due to geoblocking/proprietary media issues.

Differential Revision: https://phabricator.services.mozilla.com/D19021

--HG--
extra : moz-landing-system : lando
2019-02-12 21:59:42 +00:00
Bryce Van Dyk
b6bbe89632 Bug 1525646 - Improve logging in MoofParser. r=jya
- Use different log levels in MoofParser. Generally Error is used for out of
  memory, while warnings are used for bad mp4s.
- Add some new logs for parsing sample description entries.
- Add logs for when we can't find a Moof or fail to read a Moov.
- Have logs be more specific for the Box they're in where possible rather than
  just log 'Moof'. E.g., when parsing the stsd box, we now log against that box,
  not 'Moof'.
- Log instead of asserting if we're given multiple encrypted sample description
  entries.  This is valid per the spec, and can happen (though we don't expect
  it), so we shouldn't assert.

Differential Revision: https://phabricator.services.mozilla.com/D19020

--HG--
extra : moz-landing-system : lando
2019-02-12 21:58:59 +00:00
Alastor Wu
7f2cafcb86 Bug 1516598 - remove 'feature-policy' checking for autoplay policy. r=cpearce,baku
From the following table, we can know the feature policy have no any effect for the autoplay result.

That is, if the document has been gesture activated, we want to playback, regardless of the status of the feature policy.
If the site has denied autoplay permission via feature policy, if the user gesture activates (clicks play) we still want to be able to play.

Therefore, we can remove `feature-policy` checking.

| gesture activated | autoplay feature policy status | allowed to play |
|-------------------|--------------------------------|-----------------|
| activated         | allowed                        | true            |
| not activated     | not allowed                    | false           |
| activated         | not allowed                    | true            |
| not activated     | allowed                        | false           |

Differential Revision: https://phabricator.services.mozilla.com/D18098

--HG--
extra : moz-landing-system : lando
2019-02-12 18:21:58 +00:00
Jonathan Kingston
3421b8fcff Bug 1520868 - Replacing AsyncOpen2 with AsyncOpen always r=valentin
Replacing js and text occurences of asyncOpen2
Replacing open2 with open

Differential Revision: https://phabricator.services.mozilla.com/D16885

--HG--
rename : layout/style/test/test_asyncopen2.html => layout/style/test/test_asyncopen.html
extra : moz-landing-system : lando
2019-02-12 16:08:25 +00:00
Jean-Yves Avenard
8be6b34abb Bug 1525507 - P1. Don't trust mp4 container to determine if a VP9 frame is a keyframe. r=bryce
Similar to what we do for H264 and for vp9 in webm, we parse the VP9 bytestream and check if a frame is a keyframe there instead.

Differential Revision: https://phabricator.services.mozilla.com/D18790

--HG--
extra : moz-landing-system : lando
2019-02-06 20:34:39 +00:00
Jan-Ivar Bruaroey
0ed9f377cc Bug 1523958 - FeaturePolicy: display-capture. r=baku
Differential Revision: https://phabricator.services.mozilla.com/D18083

--HG--
extra : moz-landing-system : lando
2019-02-11 23:02:38 +00:00
Alex Gaynor
a4cf44b3f8 Bug 1525199 - Part 1 - removed size_t from IPDL messages for Cameras; r=gcp
Differential Revision: https://phabricator.services.mozilla.com/D19191

--HG--
extra : moz-landing-system : lando
2019-02-10 10:24:34 +00:00
Paul Adenot
1711340313 Bug 1524648 - Relax assertion in MediaEngineWebRTCMicrophoneSource::Deallocate to take into account the fact that starting the device can have failed. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D18979

--HG--
extra : moz-landing-system : lando
2019-02-11 09:05:08 +00:00
Narcis Beleuzu
61c7d6b9f5 Backed out changeset b350508a425c (bug 1524648) for bustages on MediaEngineWebRTCAudio.cpp . CLOSED TREE 2019-02-11 10:57:27 +02:00
Paul Adenot
d2d300dd7d Bug 1524648 - Relax assertion in MediaEngineWebRTCMicrophoneSource::Deallocate to take into account the fact that starting the device can have failed. r=pehrsons
Differential Revision: https://phabricator.services.mozilla.com/D18979

--HG--
extra : moz-landing-system : lando
2019-02-11 05:48:49 +00:00
Jean-Yves Avenard
ef00c51648 Bug 1525230 - Reset ImageRect when resolution change. r=bryce
VideoInfo.mImageRect is typically only used for VP8/VP9 content, however the Windows decoder use a common code between H264 and VP8/VP9 decoding and use this data to determine the image size. So we end up with conflicting image size and image rect (which contains cropping data).

Differential Revision: https://phabricator.services.mozilla.com/D18976

--HG--
extra : moz-landing-system : lando
2019-02-07 14:56:44 +00:00
Alastor Wu
edf9b8deac Bug 1517324 - part2: add autoplay test for createMediaStreamSource() with active stream r=karlt
Differential Revision: https://phabricator.services.mozilla.com/D18577

--HG--
extra : moz-landing-system : lando
2019-02-06 23:07:02 +00:00
Alastor Wu
154304a084 Bug 1517324 - part1 : try to start blocked AudioContext with active MediaStreamAudioSourceNode stream r=karlt
This patch would try to start a blocked AudioContext when it creates a MediaStreamAudioSourceNode which has an active input stream or when a node's inactive stream becomes active, which means someone is feeding input data to AudioContext.

Therefore, we can do the similar thing like what we did for AudioScheduledSourceNode and MediaElementAudioSourceNode, to start AudioContext if current autoplay policy has allowed AudioContext to start.

Differential Revision: https://phabricator.services.mozilla.com/D18576

--HG--
extra : moz-landing-system : lando
2019-02-06 23:14:09 +00:00
Karl Tomlinson
ad3740ae59 bug 1516956 keep AudioContext alive from AudioWorklet r=baku
to keep the graph/worklet thread running as long as the Worklet is alive.

Differential Revision: https://phabricator.services.mozilla.com/D15802

--HG--
extra : moz-landing-system : lando
2019-01-31 07:16:31 +00:00
Karl Tomlinson
f5728da157 Bug 1516956 traverse AudioWorklet from AudioContext r=baku
Differential Revision: https://phabricator.services.mozilla.com/D15801

--HG--
extra : moz-landing-system : lando
2019-01-09 18:51:51 +00:00
Alex Gaynor
0f01791ffc Bug 1512990 - Part 4 - remove declarations of Recv/Answer methods from IPDL protocol base class; r=froydnj
For cases where the class has direct calls (that is, we cast `this` to the
subclass before making the call) no longer declare Recv/Answer methods on the
base class at all. This should ensure that slots for them are not generated in
vtables, and also allow the derived class to choose the method signature (e.g.
whether it wants to take something by reference or by value).

Differential Revision: https://phabricator.services.mozilla.com/D18132

--HG--
extra : moz-landing-system : lando
2019-02-06 15:58:43 +00:00
Alex Gaynor
984f0333ea Bug 1512990 - Part 3 - remove declarations of Alloc/Dealloc methods from IPDL protocol base class; r=froydnj
For cases where the class has direct calls (that is, we cast `this` to the
subclass before making the call) no longer declare Alloc/Dealloc methods on the
base class at all. This should ensure that slots for them are not generated in
vtables, and also allow the derived class to choose the method signature (e.g.
whether it wants to take something by reference or by value).

Differential Revision: https://phabricator.services.mozilla.com/D18131

--HG--
extra : moz-landing-system : lando
2019-02-06 15:58:07 +00:00
Alex Gaynor
75c7d1fa76 Bug 1512990 - Part 2 - implement direct calls in the IPDL compiler; r=froydnj
When calling a Recv/Alloc/Dealloc method on most types, cast `this` to the
derived class.

There is a heuristic to figure out what the correct derived type is. There is a
blacklist of types which we can't do direct calls on for the moment, as well as
an override for types that do work with direct calls but which don't match the
heuristic.

Differential Revision: https://phabricator.services.mozilla.com/D16492

--HG--
extra : moz-landing-system : lando
2019-02-06 15:57:37 +00:00
Cosmin Sabou
37e54dc3ca Bug 1516754 - Fix eslint failure. r=eslint-fix 2019-02-06 06:53:12 +02:00
Jean-Yves Avenard
d3949f6fee Bug 1516754 - P2. Add mochitest. r=drno
Check that we can resume after appening a partial media segment header and calling abort().

Depends on D18651

Differential Revision: https://phabricator.services.mozilla.com/D18762

--HG--
extra : moz-landing-system : lando
2019-02-06 02:08:06 +00:00
Jean-Yves Avenard
6e021f1b1f Bug 1516754 - P1. Reset Pending Input Buffer during Reset Parser State Algorithm. r=kinetik
Differential Revision: https://phabricator.services.mozilla.com/D18651

--HG--
extra : moz-landing-system : lando
2019-02-06 00:30:35 +00:00
Alastor Wu
9b9c5c38d9 Bug 1524026 - part 2 : add test. r=padenot,smaug
Differential Revision: https://phabricator.services.mozilla.com/D18408

--HG--
extra : moz-landing-system : lando
2019-02-05 22:50:42 +00:00
Alastor Wu
0d138f528c Bug 1524026 - part1 : to allow 'AudioContext::GetAllStreams()' to get helper streams. r=padenot
The helper stream which is created by the AudioParam can't be directly got from the AudioNode, which means that we can't suspend/resume all streams related with the AudioNode.

Therefore, we should also append these streams when AudioContext requires all streams.

Differential Revision: https://phabricator.services.mozilla.com/D18296

--HG--
extra : moz-landing-system : lando
2019-02-05 22:54:09 +00:00
Jan-Ivar Bruaroey
a35b931962 Bug 1522773 - Reject any outstanding DOMMediaStream::TrackPort::BlockSourceTrackId() promise on teardown to avoid recent debug assert permafail. r=bwc
Differential Revision: https://phabricator.services.mozilla.com/D18590

--HG--
extra : moz-landing-system : lando
2019-02-05 20:59:52 +00:00
Ehsan Akhgari
786727c91d Bug 1525057 - Ensure that GetUserMediaRequest's mIsHandlingUserInput is always initialized properly; r=jib
Differential Revision: https://phabricator.services.mozilla.com/D18572

--HG--
extra : moz-landing-system : lando
2019-02-05 18:40:21 +00:00
Alastor Wu
edbdb185d6 Bug 1412231 - do not suspend/resume the AudioContext after the shutdown. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D18581

--HG--
extra : moz-landing-system : lando
2019-02-05 15:33:11 +00:00
Jed Davis
bcff2dd108 Bug 1487287 - Synchronize GeckoChildProcessHost destruction with launching. r=mccr8
In order to enable asynchronous launch, destruction of
GeckoChildProcessHost (and its subclasses) has to be delayed until after
launching (or anything else that might be made asynchronous in the
future) has completed, to prevent use-after-free.  However, there are
other dependencies on process hosts always being destroyed on the I/O
thread, so refcounting would be difficult to use.

Instead, GeckoChildProcessHost now may not be destroyed directly, but
must go through a method that handles the scheduling.

There are also some minor cleanups to the affected headers (removed
duplicate access modifiers, and made PluginProcessParent final).

Depends on D18010

Differential Revision: https://phabricator.services.mozilla.com/D18011

--HG--
extra : moz-landing-system : lando
2019-02-05 00:15:20 +00:00
Jean-Yves Avenard
864ca81cfc Bug 1524500 - P2. Simplify logic to break loop early. r=bryce
The logic was redundant with the next step that will already remove all until the next keyframe.

Depends on D18321

Differential Revision: https://phabricator.services.mozilla.com/D18322

--HG--
extra : moz-landing-system : lando
2019-02-01 17:45:38 +00:00
Jean-Yves Avenard
8701ff5245 Bug 1524500 - P1. Remove partial frames when the starting time falls within the removal interval. r=bryce
Per spec:
https://w3c.github.io/media-source/#sourcebuffer-coded-frame-removal
Step 3 of the Coded Frame Removal Interval:
"Remove all media data, from this track buffer, that contain starting timestamps greater than or equal to start and less than the remove end timestamp. "

So to decide if a frame should be removed from a track buffer, its start time is the only information to be used.

Differential Revision: https://phabricator.services.mozilla.com/D18321

--HG--
extra : moz-landing-system : lando
2019-02-01 22:58:08 +00:00
Daniel Varga
69d3c6c61d Merge mozilla-inbound to mozilla-central. a=merge
--HG--
rename : toolkit/components/passwordmgr/test/test_xhr.html => toolkit/components/passwordmgr/test/mochitest/test_xhr.html
2019-02-02 11:44:15 +02:00
Boris Zbarsky
12266da44b Bug 1521907 part 4. Start using CheckedUnwrapStatic/Dynamic in non-binding DOM code. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D17884

--HG--
extra : moz-landing-system : lando
2019-02-02 03:24:22 +00:00
Gurzau Raul
44e4d42e8a Backed out 7 changesets (bug 1521907) for failing at unit/test_bug1151385.js on a CLOSED TREE.
Backed out changeset ef04359ccf0d (bug 1521907)
Backed out changeset ac1c61bf61e9 (bug 1521907)
Backed out changeset df09b7be63c5 (bug 1521907)
Backed out changeset 585fa0024d46 (bug 1521907)
Backed out changeset e593c29aaff4 (bug 1521907)
Backed out changeset ac2e180a35b6 (bug 1521907)
Backed out changeset 270b1db9ea81 (bug 1521907)
2019-02-02 00:58:16 +02:00
Boris Zbarsky
76e1fab0c7 Bug 1521907 part 4. Start using CheckedUnwrapStatic/Dynamic in non-binding DOM code. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D17884

--HG--
extra : moz-landing-system : lando
2019-02-01 18:48:36 +00:00
Bryce Van Dyk
4f095e63a3 Bug 1523683 - Use mozilla::Variant to select if the MoofParser should parse a single track or multiple. r=jya
Using a variant more clearly indicates how MoofParser works: you cannot request
a specific track id and to parse all tracks. Callers must now explicitly select
one or the other.

Differential Revision: https://phabricator.services.mozilla.com/D18135

--HG--
extra : moz-landing-system : lando
2019-02-01 21:34:37 +00:00
Csoregi Natalia
9423fa7897 Merge mozilla-central to mozilla-inbound. CLOSED TREE 2019-02-02 00:14:12 +02:00
Ciure Andrei
63b0f3f854 Backed out 7 changesets (bug 1521907) for JSObject Wrapper.cpp bustages and failures CLOSED TREE
Backed out changeset ce3108090e77 (bug 1521907)
Backed out changeset efd05f4979f1 (bug 1521907)
Backed out changeset 2d0895148907 (bug 1521907)
Backed out changeset 192152fe986a (bug 1521907)
Backed out changeset ca65b46b0d37 (bug 1521907)
Backed out changeset b3daf5ca3d11 (bug 1521907)
Backed out changeset 1b0a09a46c70 (bug 1521907)
2019-02-01 19:38:25 +02:00
Boris Zbarsky
b014cb9758 Bug 1521907 part 4. Start using CheckedUnwrapStatic/Dynamic in non-binding DOM code. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D17884

--HG--
extra : moz-landing-system : lando
2019-01-31 15:51:52 +00:00
Chun-Min Chang
a03dc03a88 Bug 1521214 - r=kinetik
--HG--
extra : rebase_source : e9a7ece9902f1be7a43567078e3771fa359e4d61
2019-01-22 11:21:23 -08:00
Emma Humphries
657bf72d5f Bug 1521325 - TrackUnionStream.cpp: Value stored to 'inputTrackEndPoint' is never read. r=pehrsons
This is a change suggested by static analysis: http://sylvestre.ledru.info/reports/fx-scan-build/report-TrackUnionStream.cpp-CopyTrackData-24-1.html#EndPath

The condition that triggers the line in question breaks out of the loop.

```
for (some range)
  value = foo

  if (condition) {
    value = bar // the line in question
    break;
  }

  /* use value */

end
```

So if the condition is triggered, we leave the loop before `value` is used.

Differential Revision: https://phabricator.services.mozilla.com/D18169

--HG--
extra : moz-landing-system : lando
2019-02-01 06:09:04 +00:00
Andrew McCreight
f68a0b40f7 Bug 1522951 - Make ChromiumCDMProxy::mCrashHelper into a strong reference. r=jya
Refcounted objects should be put into refptrs when they are created.

This patch also moves the crash helper out of the object early in
Init, to maybe reduce the chance of a leak if it fails early.

This field is only used to pass in a value to the Init() method. It
can't be passed in directly because on Android there are two
implementations of CDMProxy, and MediaDrmCDMProxy doesn't take a crash
helper.

Differential Revision: https://phabricator.services.mozilla.com/D17707

--HG--
extra : moz-landing-system : lando
2019-02-01 00:20:19 +00:00
Jean-Yves Avenard
a8cac91ece Bug 1524119 - Properly get VP9 benchmark value. r=bryce
And not the threshold which is always 150.

Differential Revision: https://phabricator.services.mozilla.com/D18159

--HG--
extra : moz-landing-system : lando
2019-01-31 17:55:45 +00:00
arthur.iakab
e91653a3fb Backed out changeset d37ccbbcd36d (bug 1522951) for Android build bustages on MediaDrmCDMProxy.h CLOSED TREE 2019-01-31 22:42:35 +02:00
Andrew McCreight
4ec91b01d2 Bug 1522951 - Get rid of ChromiumCDMProxy::mCrashHelper. r=jya
This field is only used to pass a pointer from the ctor to the Init()
method. Instead, just pass in the crash helper directly.

This avoids some problems with the existing code where the crash
helper is not AddRefed immediately after creation, which could lead to
leaks in some error cases.

Differential Revision: https://phabricator.services.mozilla.com/D17707

--HG--
extra : moz-landing-system : lando
2019-01-31 20:14:31 +00:00
David Major
1ad5d6e1f1 Bug 1524087 - Use exp2 instead of pow in OscillatorNode r=padenot
Clang 7 was making the pow => exp2 optimization for us, and for some reason clang 8 stopped doing so. This resulted in a surprisingly large regression in raptor numbers.

Differential Revision: https://phabricator.services.mozilla.com/D18148

--HG--
extra : moz-landing-system : lando
2019-01-31 15:11:35 +00:00
Andreas Pehrson
ce0e20a4ee Bug 1407650 - Avoid test_mr_record_changing_video_resolution.html by delaying stop(). r=jib
Differential Revision: https://phabricator.services.mozilla.com/D18050

--HG--
extra : moz-landing-system : lando
2019-01-31 04:18:02 +00:00
Andrew McCreight
0f605627fd Bug 1523013 - Clear SamplesWaitingForKey::mProxy in Shutdown(). r=cpearce
There's a strong cycle of references between SamplesWaitingForKey and
CDMProxy that does not get cleared unless keys actually come in. This
causes a leak. One way to avoid that leak is to clear the proxy
reference when the things holding the SamplesWaitingForKey is shut
down.

Differential Revision: https://phabricator.services.mozilla.com/D17960

--HG--
extra : moz-landing-system : lando
2019-01-30 22:56:21 +00:00
Myk Melez
25349d2601 Bug 1518283 - prohibit blank lines at the beginning and end of blocks (eslint padded-blocks) r=mossop,Standard8
Differential Revision: https://phabricator.services.mozilla.com/D17526

--HG--
extra : moz-landing-system : lando
2019-01-30 17:26:25 +00:00
Mike Hommey
e39820dc70 Bug 1475564 - Enable libav1 when not building with msvc. r=dmajor
We reenable the corresponding tests unconditionally because we don't run
tests on the msvc builds anyways (and they're going to be retired soon).

Differential Revision: https://phabricator.services.mozilla.com/D18028

--HG--
extra : moz-landing-system : lando
2019-01-30 07:30:01 +00:00
shindli
d5c5369355 Merge inbound to mozilla-central. a=merge 2019-01-29 23:37:33 +02:00
Sebastian Hengst
7661c7c260 Merge mozilla-central to mozilla-inbound 2019-01-29 12:55:03 +02:00