Commit Graph

14518 Commits

Author SHA1 Message Date
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
Cosmin Sabou
599a15d354 Merge mozilla-inbound to mozilla-central. a=merge 2019-01-29 12:01:56 +02:00
Bob Owen
c10c92ae4e Bug 1511438 Part 2: Enable win32k lockdown on RDD process. r=jimm
This stops the use of some win32k calls during start-up that will fail and in
some cases cause a crash.

It also moves the MITIGATION_DYNAMIC_CODE_DISABLE to be enabled after start-up.
This is required because the hooks to fake the user32 and gdi32 initialization
are applied as the DLLs load and the dynamic code disable blocks that.
2019-01-29 08:49:13 +00:00
Sebastian Hengst
b78e4e8667 Merge mozilla-central to mozilla-inbound
--HG--
rename : browser/components/urlbar/tests/legacy/browser_urlbar_search_no_speculative_connect_with_client_cert.js => browser/components/urlbar/tests/browser/browser_urlbar_speculative_connect_not_with_client_cert.js
2019-01-29 02:55:55 +02:00
Andreas Pehrson
4153810bc8 Bug 1521577 - Don't block a MediaStream where at least one track is pulled. r=achronop
With the per-track pulling settings we have today it is clearly the intention
of the producer to start consuming a track that has pulling enabled, even if
there are other tracks where pulling is disabled.

This patch fixes that, so that when a stream has at least one pulled track it
will append null data to other tracks (commonly video) if they are lacking
data.

This means that we still block an entire stream if all tracks have pulling
disabled - to maintain the status quo for media element capture, which is
the only push-only producer of data.

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

--HG--
extra : moz-landing-system : lando
2019-01-28 07:26:03 +00:00
Bryce Van Dyk
ae94ea871a Bug 1519919 - Add gtest for the MoofParser handling moovs with multiple tracks followed by moofs with only 1 track. r=jya
Add a test file that has a moov with two tracks, but which has had the track
fragment headers removed for the second track. Created from bipbop.mp4 via:
`mp4box bipbop.mp4 -dash 5000 -subsegs-per-sidx -1 -segment-name
$Segment=bipbop_$$Init=bipbop_init$`, concatenating the init and segments
back into an mp4, then overwriting track 2's trafs with frees.

While we shouldn't expect people to create files such as this, it does simulate
if the MoofParser is fed metadata for multiple tracks, but then is not fed
fragments for one of these tracks. This appears to have been the case when bug
1519617 broke soundcloud.com, so we should have test coverage for this.

Depends on D17070

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

--HG--
extra : moz-landing-system : lando
2019-01-29 01:14:23 +00:00
Bryce Van Dyk
af8ad0e3e2 Bug 1519919 - Add gtest to check the MoofParser handles crypto when parsing tracks with track_id 0. r=jya
Test that an init segment for a video track that uses track_id 0 is correctly
parsed and that the MoofParser picks up the expected crypto data.

Depends on D17069

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

--HG--
extra : moz-landing-system : lando
2019-01-28 20:04:53 +00:00
Bryce Van Dyk
bbaf9090c4 Bug 1519919 - Add gtest to ensure MoofParser does not parse all tracks when given track_id 0. r=jya
Add a copy of bipbop.mp4 that has been fragmented via `mp4box.exe bipbop.mp4
-dash 10000 -subsegs-per-sidx -1` and then hex edited the track_id for video to
be 0. Add this to our already existing MP4Metadata and MoofParser gtests.

Also construct a new gtest to ensure that requesting track 0 from the MoofParser
doesn't result in all tracks being parsed. Historically this would have happened
and could result in bad metadata if the caller expected just track 0 to be
parsed.

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

--HG--
extra : moz-landing-system : lando
2019-01-28 20:04:11 +00:00
Andreas Pehrson
6c44eb1372 Bug 1523817 - Fix tracks that start at StreamTime t > 0. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D18312

--HG--
extra : moz-landing-system : lando
2019-02-01 13:44:44 +00:00
Timothy Guan-tin Chien
d59f80985c Bug 1507895 - Part I, Remove the videocontrols binding r=smaug
This patch removes the XBL videocontrols binding and make <video>
to always use the UA Widget to generate controls.

DevTools tests that look for NAC is switched to use <input type=file>.

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

--HG--
extra : moz-landing-system : lando
2019-01-25 13:12:26 +00:00
Alex Chronopoulos
c7a3f72677 Bug 1522488 - Increase wait time before a new device enumeration after a device change event to avoid getting outdated list. r=padenot
The problem here is that the MediaStreamGraphImpl::mInputDeviceID is not reset after a device unplug. On a device-remove event of the active device MediaStreamGraphImpl::mInputDeviceID is reset when MediaStreamGraphImpl::CloseAudioInput is being executed. This method will not be executed if the new enumeration, on the MediaManager::OnDeviceChange, is returning the old outdated list of devices. This patch increases the wait time before the new enumeration in order to allow the system to update the provided device list.

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

--HG--
extra : moz-landing-system : lando
2019-01-28 17:36:07 +00:00
John Lin
e4a543d886 Bug 1517252 - p1: don't lock HLSResourceCallbacksSupport mutex unnecessarily. r=jya
HLSResourceCallbacksSupport::mDecoder is cleared on main thread too, so
the nullness check already ensures decoder methods won't be called after
shut down. In fact, for OnError() the lock is harmful because the task calls
MediaDecoder::NetworkError(), which triggers decoder shutdown and eventually
HLSResourceCallbacksSupport::Detach(), which tries to lock the mutex again
while the mutex is still locked.

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

--HG--
extra : moz-landing-system : lando
2019-01-22 22:55:58 +00:00
Kris Maglione
e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

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

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Sebastian Hengst
2ecf173b14 Merge mozilla-central to autoland 2019-01-23 11:31:44 +02:00
alwu
8d172019f3 Bug 1519317 - handle non decoding errors when we seek back to the start position. r=jya
'NS_ERROR_DOM_MEDIA_WAITING_FOR_DATA' and 'NS_ERROR_DOM_MEDIA_CANCELED' are not decoding errors, so we should
 treat them differently like what we did for 'NS_ERROR_DOM_MEDIA_END_OF_STREAM'.

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

--HG--
extra : moz-landing-system : lando
2019-01-22 23:18:54 +00:00
Sylvestre Ledru
0b4021fcad Bug 1521460 - Also reformat objective-c files r=mstange,ehsan,spohl
# ignore-this-changeset

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

--HG--
extra : histedit_source : 084f340503d2e1a2d9e1753c38b2c4ee9c7819f3
2019-01-21 18:18:16 +01:00
Cosmin Sabou
7ccc9d8b0b Merge mozilla-inbound to mozilla-central. a=merge 2019-01-19 11:57:49 +02:00
Alastor Wu
d929d261a0 Bug 1519430 - part3 : add test. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D16614

--HG--
extra : moz-landing-system : lando
2019-01-18 18:23:44 +00:00
Alastor Wu
9bb36dab32 Bug 1519430 - part2 : only resume AudioContext which is blocked by autoplay policy. r=padenot
We would only start the AudioContext blocked by our autoplay policy, won't resume AudioContext which is suspended explictly by page.

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

--HG--
extra : moz-landing-system : lando
2019-01-18 18:23:58 +00:00