889 Commits

Author SHA1 Message Date
deadbeef
ffbe0e17e2 Improving the fake clock and using it to fix a flaky STUN timeout test.
When the fake clock's time is advanced, it now ensures all pending
queued messages have been dispatched. This allows us to write a
"SIMULATED_WAIT" macro that ticks the simulated clock by milliseconds up
until the target time.

Useful in this case, where we know the STUN timeout should take a total
of 9500ms, but it would be overly complex to write test code that waits
for each individual timeout, ensures a STUN packet has been
retransmited, etc.

(The test described above *should* be written, but it belongs in
p2ptransportchannel_unittest.cc, not webrtcsession_unittest.cc).

Review-Url: https://codereview.webrtc.org/2024813004
Cr-Commit-Position: refs/heads/master@{#13043}
2016-06-03 22:31:37 +00:00
deadbeef
d50f4f331e Fixing flaky SignalThread tests.
Using an "EXPECT_WAIT" pattern with a long timeout rather than calling
"SleepMs" with a margin of 250ms.

BUG=webrtc:5953

Review-Url: https://codereview.webrtc.org/2029853002
Cr-Commit-Position: refs/heads/master@{#13040}
2016-06-03 17:31:07 +00:00
kjellander@webrtc.org
3ee5614650 GN: Add rtc_unittests
Everything except the dependency on
sdk/sdk_tests.gyp:rtc_sdk_peerconnection_objc_tests is included.
That one actually doesn't make those tests run as part of rtc_unittests
(by design). Fixing that + add them will done in aseparate CL.

BUG=webrtc:5949
TESTED=Built and ran rtc_unittests on Mac.
Verified the number of tests matched a run on the bot (1213 tests executed).

R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/2034923003 .

Cr-Commit-Position: refs/heads/master@{#13036}
2016-06-03 13:57:06 +00:00
ossu
a8aa907639 Disabled two flaky subtests of SignalThreadTest.
BUG=webrtc:5953

Review-Url: https://codereview.webrtc.org/2029523002
Cr-Commit-Position: refs/heads/master@{#13019}
2016-06-02 15:47:12 +00:00
sprang
52033d6ea1 Add H264 bitstream rewriting to limit frame reordering marker in header
The VUI part an SPS may specify max_num_reorder_frames and
max_dec_frame_buffering. These may cause a decoder to buffer a number
of frame prior allowing decode, leading to delays, even if no frames
using such references (ie B-frames) are sent.

Because of this we update any SPS block emitted by the encoder.

Also, a bunch of refactoring of H264-related code to reduce code
duplication.

BUG=

Review-Url: https://codereview.webrtc.org/1979443004
Cr-Commit-Position: refs/heads/master@{#13010}
2016-06-02 09:43:38 +00:00
kjellander
26306b139a Remove test targets of type none.
Move the sources of rtc_unittests and xmllite_xmpp_unittests
into the actual targets instead of depending on none-targets.
This will make it easier to create GN targets matching them.

BUG=webrtc:5949
NOTRY=True
NOPRESUBMIT=True

Review-Url: https://codereview.webrtc.org/2029583002
Cr-Commit-Position: refs/heads/master@{#13008}
2016-06-02 09:26:10 +00:00
kjellander
bac0412e7f GN: Add system_wrappers_unittests, tools and tools_unittests
BUG=webrtc:5949
TESTED=Built and ran the tests on Mac.
NOTRY=True

Review-Url: https://codereview.webrtc.org/2025343002
Cr-Commit-Position: refs/heads/master@{#13007}
2016-06-02 09:18:57 +00:00
Taylor Brandstetter
98cde26c78 Use scoped_refptr for On(Add|Remove)Stream and OnDataChannel.
This will make it much less likely for application developers to not
realize the object is reference counted.

It also fixes a bug in the Java PeerConnection binding, by allowing a
reference to be transferred in the OnRemoveStream call via std::move.

BUG=webrtc:5128
R=pthatcher@webrtc.org, tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1972793003 .

Cr-Commit-Position: refs/heads/master@{#12976}
2016-05-31 20:02:30 +00:00
ossu
22e70ab1dd Disabled ProfilerTest.TestFunction due to flakiness.
BUG=webrtc:5947

Review-Url: https://codereview.webrtc.org/2021743003
Cr-Commit-Position: refs/heads/master@{#12960}
2016-05-30 14:36:27 +00:00
Taylor Brandstetter
b3c6810be3 Adding the ability to use a simulated clock for unit tests.
This will be useful for any tests that test objects with time-dependent
behavior. It will allow such tests to be written in such a way that their
outcome is more repeatable (less flaky), and will also allow such tests
to finish quicker. For example, a test for STUN timeout doesn't need to
wait the full timeout interval in real time; it can simply advance the
simulated clock.

BUG=webrtc:4925
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1895933003 .

Cr-Commit-Position: refs/heads/master@{#12950}
2016-05-27 21:16:07 +00:00
Peter Boström
0ec9a9b9fc Lower event-tracing log-thread priority.
Lowers risk of the event-tracing thread affecting measurements (and
performance of device). Entirely speculative, but shouldn't hurt.
Timings are still done on the thread that calls the trace macros.

BUG=
R=tommi@webrtc.org

Review URL: https://codereview.webrtc.org/2013363002 .

Cr-Commit-Position: refs/heads/master@{#12943}
2016-05-27 09:11:52 +00:00
nisse
a44e72c44f Call java SurfaceTextureHelper.dispose from the corresponding C++ destructor.
This makes it clearer that the C++ SurfaceTextureHelper owns its associated java object it.

In addition, arrange so that the SurfaceTextureHelper.stopListening
method (in java) can be called from any thread.

BUG=

Review-Url: https://codereview.webrtc.org/1988043002
Cr-Commit-Position: refs/heads/master@{#12941}
2016-05-27 07:28:05 +00:00
Honghai Zhang
63ab810ce2 Set IOS Wifi interface type based on the interface name.
BUG=webrtc:3149
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/2006893003 .

Cr-Commit-Position: refs/heads/master@{#12939}
2016-05-27 03:30:27 +00:00
hbos
41c5cd02fc Making ECDSA the default certificate regardless of WEBRTC_CHROMIUM_BUILD.
Due to the experiment in chromium relying on KT_DEFAULT = KT_RSA (bug:
crbug.com/611698) a conditional was introduced. Now that the experiment is
ending and the experiment flag has been removed we can make KT_DEFAULT=KT_ECDSA
unconditionally.

BUG=chromium:611698

Review-Url: https://codereview.webrtc.org/2009533003
Cr-Commit-Position: refs/heads/master@{#12935}
2016-05-26 22:23:21 +00:00
Henrik Boström
300450b4b8 Increase the rtccertificategenerator_unittest.cc certificate generation timeout
to hopefully avoid a timeout flake on the bots.

R=hta@webrtc.org

Review URL: https://codereview.webrtc.org/2012563003 .

Cr-Commit-Position: refs/heads/master@{#12889}
2016-05-25 12:06:43 +00:00
Henrik Boström
6c96314b42 RTCCertificateGeneratorInterface and RTCCertificateGeneratorStoreWrapper added.
This CL adds these classes but does not change any functonality or interface
yet. This is in preparation for future CLs. To be used for this:
https://codereview.webrtc.org/2000163002/

RTCCertificateGenerator is meant to replace DtlsIdentityStoreInterface and
implementations. In order to continue to support mocking and to help with the
transition, RTCCertificateGenerator gets an interface that it implements (just
like the store has both interface and impl).

PeerConnectionFactoryInterface::CreatePeerConnection will take an
RTCCertificateGeneratorInterface instead of DtlsIdentityStoreInterface. As to
not break Chromium, both versions of CreatePeerConnection need to exist for a
transition period. This will be done by wrapping a store into a generator
wrapper - RTCCertificateGeneratorStoreWrapper.

BUG=webrtc:5707, webrtc:5708
R=hta@webrtc.org, tommi@chromium.org, tommi@webrtc.org

Review URL: https://codereview.webrtc.org/2001103002 .

Cr-Commit-Position: refs/heads/master@{#12879}
2016-05-24 18:46:42 +00:00
tommi
09c60da704 Split TaskQueue out into a separate build target.
This is needed as there are targets such as newlib_pnacl/remoting_client_plugin_newlib.pexe that depend on rtc_base_approved but don't need TaskQueue. We could implement support for TaskQueue in nacl using ppapi types, but it looks like there isn't a need for it. Libevent isn't supported for nacl either, so I'm introducing a layer on top of rtc_base_approved for TaskQueue.  It's conceivable that this target will morph into a target that holds other threading primitives such as platform_thread and possibly socket related operations, which is also an area that we currently #ifdef out for nacl in a few places.

Functional change: Removes the "is_nacl" check.

R=phoglund@webrtc.org

Review-Url: https://codereview.webrtc.org/2001913002
Cr-Commit-Position: refs/heads/master@{#12878}
2016-05-24 18:40:44 +00:00
philipel
49c0869825 Revert of Change initial DTLS retransmission timer from 1 second to 50ms. (patchset #2 id:20001 of https://codereview.webrtc.org/1981463002/ )
Reason for revert:
Seems like this CL cause
DtlsTransportChannelTest.TestReceiveClientHelloBeforeRemoteFingerprint
DtlsTransportChannelTest.TestReceiveClientHelloBeforeWritable
to consistently fail on Win DrMemory Full and for
DtlsTransportChannelTest.TestReceiveClientHelloBeforeRemoteFingerprint
DtlsTransportChannelTest.TestReceiveClientHelloBeforeWritable
to consistently fail on Linux Memcheck

Original issue's description:
> Change initial DTLS retransmission timer from 1 second to 50ms.
>
> This will help ensure a timely DTLS handshake when there's packet
> loss. It will likely result in spurious retransmissions (since the
> RTT is usually > 50ms), but since exponential backoff is still used,
> there will at most be ~4 extra retransmissions. For a time-sensitive
> application like WebRTC this seems like a reasonable tradeoff.
>
> R=juberti@chromium.org, juberti@webrtc.org, pthatcher@webrtc.org
>
> Committed: https://crrev.com/1e435628366fb9fed71632369f05928ed857d8ef
> Cr-Commit-Position: refs/heads/master@{#12853}

TBR=pthatcher@webrtc.org,juberti@webrtc.org,juberti@chromium.org,deadbeef@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review-Url: https://codereview.webrtc.org/2002403002
Cr-Commit-Position: refs/heads/master@{#12864}
2016-05-24 08:49:46 +00:00
Stefan Holmer
5b53b0eeb4 Remove timing dependent packet checks from socket tests.
This avoids flaky tests and the check itself doesn't provide much value anyway.

TBR=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/2005993002 .

Cr-Commit-Position: refs/heads/master@{#12855}
2016-05-23 20:56:22 +00:00
Taylor Brandstetter
1e43562836 Change initial DTLS retransmission timer from 1 second to 50ms.
This will help ensure a timely DTLS handshake when there's packet
loss. It will likely result in spurious retransmissions (since the
RTT is usually > 50ms), but since exponential backoff is still used,
there will at most be ~4 extra retransmissions. For a time-sensitive
application like WebRTC this seems like a reasonable tradeoff.

R=juberti@chromium.org, juberti@webrtc.org, pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1981463002 .

Cr-Commit-Position: refs/heads/master@{#12853}
2016-05-23 19:49:00 +00:00
Stefan Holmer
3ebb3efd13 Don't read socket timestamps when building native client.
BUG=webrtc:5773
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/2008573002 .

Cr-Commit-Position: refs/heads/master@{#12851}
2016-05-23 18:26:25 +00:00
Stefan Holmer
9131efdb30 Read recv timestamps from socket (posix only).
This helps a lot on Android devices where the user threads can be scheduled with low priority when the app is in the background, causing spurious significantly delayed before a packet can be read from the socket. With this patch the timestamp is taken by the kernel when the packet actually arrives.

R=juberti@chromium.org
TBR=juberti@webrtc.org

BUG=webrtc:5773

Review URL: https://codereview.webrtc.org/1944683002 .

Cr-Commit-Position: refs/heads/master@{#12850}
2016-05-23 16:19:37 +00:00
Honghai Zhang
351d77b702 Update the type and cost of existing networks
if the network monitor detects it after the native code does.

Also set the network cost for ethernet, wifi, unknown, cellular network type to be 0, 10, 50, 900,
so that unknown networks will have lower precedence than known networks with low cost (like Wifi) but  higher precedence than known networks with high cost.

And third, infer network type based on limited name matching in Android if there is no network monitor or network monitor did not find the type.

BUG=webrtc:5890
R=pthatcher@chromium.org, pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1976683003 .

Cr-Commit-Position: refs/heads/master@{#12833}
2016-05-20 22:08:37 +00:00
kjellander@webrtc.org
03d45b016a base.gyp: Add conditions for NaCl builds.
These are needed to be able to cleanup the NaCl
GYP code in src/third_party/libjingle before switching
over to WebRTC's own targets.
See https://code.google.com/p/chromium/codesearch#chromium/src/third_party/libjingle/libjingle_nacl.gyp&l=260 for details.

BUG=webrtc:4256
R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1984613002 .

Cr-Commit-Position: refs/heads/master@{#12819}
2016-05-20 07:52:47 +00:00
Taylor Brandstetter
2b3bf6b7d5 Re-enabling socket tests that were previously flaky.
It's assumed that these tests were flaky because they used a non-virtual
resource (sockets) and were being run in parallel. So this should be
fixed now that these tests are now not being run in parallel, thanks to
this CL: https://codereview.webrtc.org/1426643003

BUG=webrtc:4923
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1982733002 .

Cr-Commit-Position: refs/heads/master@{#12817}
2016-05-19 21:57:40 +00:00
danilchap
8e572f030f Adds macros to annotate variables and functions used from same thread or queue.
ACCESS_ON is an alias of GUARDED_BY but should take thread-like object instead of mutex,
RUN_ON is an alias of EXCLUSIVE_LOCKS_REQUIRED to annotate function always run on same
thread/task_queue
RTC_DCHECK_RUN_ON - creates an object that allows use of annotated variables and functions, and adds a run-time DCHECK given thread/queue is current.

R=tommi@webrtc.org

Review-Url: https://codereview.webrtc.org/1981893002
Cr-Commit-Position: refs/heads/master@{#12812}
2016-05-19 13:49:10 +00:00
phoglund
ff274394fe Separate building and enabling libevent.
We're now ready https://codereview.webrtc.org/1984503002/ downstream,
so make sure we can enable libevent but still choose which libevent
implementation to use. This follows the common pattern where an enable_
flag controls whether we should use the feature at all, whereas build_
controls if we should use the dependency from our DEPS file or
something else.

NOTRY=True

Review-Url: https://codereview.webrtc.org/1980003002
Cr-Commit-Position: refs/heads/master@{#12772}
2016-05-17 10:44:36 +00:00
Henrik Boström
d98f6e000a Fixed typo. KT_DEFAULT different based on WEBRTC_CHROMIUM_BUILD
instead of WEBRTC_BUILD_CHROMIUM.

BUG=chromium:611698, webrtc:5795
R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1986053005 .

Cr-Commit-Position: refs/heads/master@{#12771}
2016-05-17 10:36:19 +00:00
hbos
8ae8ab4e23 Makes ECDSA the default certificate to use (generated if no other certificates
are specified when constructing a peer connection, at:
https://code.google.com/p/chromium/codesearch#chromium/src/third_party/webrtc/api/webrtcsessiondescriptionfactory.cc&q=webrtcsessiondescriptionfactory&sq=package:chromium&type=cs&l=191).

This does not affect WEBRTC_BUILD_CHROMIUM builds whose ECDSA launch is handled
separately: https://crbug.com/601850 (req. @chromium acc).

BUG=chromium:611698, webrtc:5795

Review-Url: https://codereview.webrtc.org/1972383002
Cr-Commit-Position: refs/heads/master@{#12756}
2016-05-16 09:45:45 +00:00
Tommi
0bcbbd345e Fix component build in chrome after recent TaskQueue cl
TBR=phoglund

Review URL: https://codereview.webrtc.org/1985533002 .

Cr-Commit-Position: refs/heads/master@{#12753}
2016-05-15 11:42:49 +00:00
kwiberg
fd8be3468a Remove webrtc/base/scoped_ptr.h
This is a re-land of https://codereview.webrtc.org/1942823002

TBR=tommi@webrtc.org
BUG=webrtc:5520

Review-Url: https://codereview.webrtc.org/1966423002
Cr-Commit-Position: refs/heads/master@{#12750}
2016-05-15 02:44:18 +00:00
tommi
c06b133b29 Reland of New task queueing primitive for async tasks: TaskQueue.
New task queueing primitive for async tasks: TaskQueue.
TaskQueue is a new way to asynchronously execute tasks sequentially
in a thread safe manner with minimal locking.  The implementation
uses OS supported APIs to do this that are compatible with async IO
notifications from things like sockets and files.
This class is a part of rtc_base_approved, so can be used by both
the webrtc and libjingle parts of the WebRTC library.  Moving forward,
we can replace rtc::Thread and webrtc::ProcessThread with this implementation.
NOTE: It should not be assumed that all tasks that execute on a TaskQueue,
run on the same thread.  E.g. on Mac and iOS, we use GCD dispatch queues
which means that tasks might execute on different threads depending on
what's the most efficient thing to do.

TBR=perkj@webrtc.org,phoglund@webrtc.org

Review-Url: https://codereview.webrtc.org/1984503002
Cr-Commit-Position: refs/heads/master@{#12749}
2016-05-14 18:31:49 +00:00
tommi
5ce1a2a629 Reland of Allow the localhost IP address even if it does not match the tcp port address (patchset #1 id:1 of https://codereview.webrtc.org/1979463003/ )
Reason for revert:
Relanding this change since the revert didn't make a difference.

Original issue's description:
> Revert of Allow the localhost IP address even if it does not match the tcp port address (patchset #4 id:120001 of https://codereview.webrtc.org/1914803002/ )
>
> Reason for revert:
> Speculatively reverting due to failures on the memcheck bot (and possibly other bots):
>
> https://build.chromium.org/p/client.webrtc/builders/Linux%20Memcheck/builds/5910/steps/video_engine_tests/logs/EndToEndTest.SendsAndReceivesH264
>
> Original issue's description:
> > This fixes an issue similar to
> > https://bugs.chromium.org/p/webrtc/issues/detail?id=3927
> > where the localhost IP does not match the turn port address.
> > The issue here is in the TCP port.
> >
> > BUG=
> > R=pthatcher@webrtc.org
> >
> > Committed: https://crrev.com/6705012904e6cbbefce6fbce0a3f615b7aeafd8f
> > Cr-Commit-Position: refs/heads/master@{#12707}
>
> TBR=pthatcher@webrtc.org,deadbeef@webrtc.org,honghaiz@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=
>
> Committed: https://crrev.com/1cbf0a73eb4b475e8beb878ea3a4d650191f0c08
> Cr-Commit-Position: refs/heads/master@{#12728}

TBR=pthatcher@webrtc.org,deadbeef@webrtc.org,honghaiz@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review-Url: https://codereview.webrtc.org/1979073002
Cr-Commit-Position: refs/heads/master@{#12746}
2016-05-14 10:19:39 +00:00
tommi
3f90087ce8 Revert of New task queueing primitive for async tasks: TaskQueue. (patchset #8 id:330001 of https://codereview.webrtc.org/1927133004/ )
Reason for revert:
sigh.  Have to revert again as there seems to have have been some change made for pnacl and CrOS.

Original issue's description:
> Reland of New task queueing primitive for async tasks: TaskQueue. (patchset #1 id:1 of https://codereview.webrtc.org/1935483002/ )
>
> New task queueing primitive for async tasks: TaskQueue.
> TaskQueue is a new way to asynchronously execute tasks sequentially
> in a thread safe manner with minimal locking.  The implementation
> uses OS supported APIs to do this that are compatible with async IO
> notifications from things like sockets and files.
>
> This class is a part of rtc_base_approved, so can be used by both
> the webrtc and libjingle parts of the WebRTC library.  Moving forward,
> we can replace rtc::Thread and webrtc::ProcessThread with this implementation.
>
> NOTE: It should not be assumed that all tasks that execute on a TaskQueue,
> run on the same thread.  E.g. on Mac and iOS, we use GCD dispatch queues
> which means that tasks might execute on different threads depending on
> what's the most efficient thing to do.
>
> TBR=perkj@webrtc.org
>
> Committed: https://crrev.com/65d1f2aba216d077c6d22488f03e56984aef1c68
> Cr-Commit-Position: refs/heads/master@{#12737}

TBR=perkj@webrtc.org,phoglund@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review-Url: https://codereview.webrtc.org/1981573002
Cr-Commit-Position: refs/heads/master@{#12738}
2016-05-13 21:33:39 +00:00
tommi
65d1f2aba2 Reland of New task queueing primitive for async tasks: TaskQueue. (patchset #1 id:1 of https://codereview.webrtc.org/1935483002/ )
New task queueing primitive for async tasks: TaskQueue.
TaskQueue is a new way to asynchronously execute tasks sequentially
in a thread safe manner with minimal locking.  The implementation
uses OS supported APIs to do this that are compatible with async IO
notifications from things like sockets and files.

This class is a part of rtc_base_approved, so can be used by both
the webrtc and libjingle parts of the WebRTC library.  Moving forward,
we can replace rtc::Thread and webrtc::ProcessThread with this implementation.

NOTE: It should not be assumed that all tasks that execute on a TaskQueue,
run on the same thread.  E.g. on Mac and iOS, we use GCD dispatch queues
which means that tasks might execute on different threads depending on
what's the most efficient thing to do.

TBR=perkj@webrtc.org

Review-Url: https://codereview.webrtc.org/1927133004
Cr-Commit-Position: refs/heads/master@{#12737}
2016-05-13 20:05:05 +00:00
tommi
1cbf0a73eb Revert of Allow the localhost IP address even if it does not match the tcp port address (patchset #4 id:120001 of https://codereview.webrtc.org/1914803002/ )
Reason for revert:
Speculatively reverting due to failures on the memcheck bot (and possibly other bots):

https://build.chromium.org/p/client.webrtc/builders/Linux%20Memcheck/builds/5910/steps/video_engine_tests/logs/EndToEndTest.SendsAndReceivesH264

Original issue's description:
> This fixes an issue similar to
> https://bugs.chromium.org/p/webrtc/issues/detail?id=3927
> where the localhost IP does not match the turn port address.
> The issue here is in the TCP port.
>
> BUG=
> R=pthatcher@webrtc.org
>
> Committed: https://crrev.com/6705012904e6cbbefce6fbce0a3f615b7aeafd8f
> Cr-Commit-Position: refs/heads/master@{#12707}

TBR=pthatcher@webrtc.org,deadbeef@webrtc.org,honghaiz@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review-Url: https://codereview.webrtc.org/1979463003
Cr-Commit-Position: refs/heads/master@{#12728}
2016-05-13 14:39:45 +00:00
Henrik Boström
e06c2ddbde JNI+mm: Generate certificate if non-default key type is specified.
By comparing key type with KT_DEFAULT we remove the implicit assumption that
the default is RSA.

Removing the assumptions about what the default is is necessary for a
follow-up CL that will change the default.

BUG=webrtc:5795, webrtc:5707
R=hta@webrtc.org, magjed@webrtc.org, tommi@webrtc.org
TBR=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1965313002 .

Cr-Commit-Position: refs/heads/master@{#12722}
2016-05-13 11:50:50 +00:00
Honghai Zhang
6705012904 This fixes an issue similar to
https://bugs.chromium.org/p/webrtc/issues/detail?id=3927
where the localhost IP does not match the turn port address.
The issue here is in the TCP port.

BUG=
R=pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1914803002 .

Cr-Commit-Position: refs/heads/master@{#12707}
2016-05-12 16:28:08 +00:00
mostynb
e38e4f6e48 IWYU: errno.h in base/logging.h
Without this, some toolchains may fail to build base/checks.cc
because errno is undefined.

NOTRY=true

Review-Url: https://codereview.webrtc.org/1971513002
Cr-Commit-Position: refs/heads/master@{#12696}
2016-05-12 08:08:29 +00:00
Henrik Kjellander
3fe372dbee Fix all -Wnon-virtual-dtor warnings.
This is needed to get the GN build going for several parts
of the code tree.

BUG=webrtc:3307
NOTRY=True
R=henrika@webrtc.org, nisse@webrtc.org

Review URL: https://codereview.webrtc.org/1928653005 .

Cr-Commit-Position: refs/heads/master@{#12693}
2016-05-12 06:11:09 +00:00
kwiberg
6ab3db249b Revert of Remove webrtc/base/scoped_ptr.h (patchset #3 id:100001 of https://codereview.webrtc.org/1942823002/ )
Reason for revert:
Breaks user code. Said code needs to stop using scoped_ptr!

Original issue's description:
> Remove webrtc/base/scoped_ptr.h
>
> BUG=webrtc:5520
>
> NOTRY=True
>
> Committed: https://crrev.com/65fc62e9dd8a8716db625aaef76ab92f542ecc5a
> Cr-Commit-Position: refs/heads/master@{#12684}

TBR=tommi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5520

Review-Url: https://codereview.webrtc.org/1965063003
Cr-Commit-Position: refs/heads/master@{#12686}
2016-05-11 12:07:33 +00:00
kwiberg
65fc62e9dd Remove webrtc/base/scoped_ptr.h
BUG=webrtc:5520

NOTRY=True

Review-Url: https://codereview.webrtc.org/1942823002
Cr-Commit-Position: refs/heads/master@{#12684}
2016-05-11 11:29:38 +00:00
kwiberg
d040480f69 rtc::Optional<T>: Don't secretly contain a default-constructed T when empty
Instead, use a neat trick with union to ensure that we have a T only
when we're supposed to (and just a bunch of unused memory otherwise).
This is how std::optional behaves, so it makes sense for us to do the
same (and it's convenient, too, since we don't have to pay for the
default-constructed T, and we support types that don't have default
constructors).

Doing this became possible recently when we dropped support for MSVC
2013, which didn't support unions containing non-trivial types.

Review-Url: https://codereview.webrtc.org/1896833004
Cr-Commit-Position: refs/heads/master@{#12664}
2016-05-09 13:06:10 +00:00
Honghai Zhang
82d7862fe7 Change default timestamp to 64 bits in all webrtc directories.
BUG=
R=pbos@webrtc.org, pthatcher@webrtc.org, solenberg@webrtc.org

Review URL: https://codereview.webrtc.org/1835053002 .

Cr-Commit-Position: refs/heads/master@{#12646}
2016-05-06 18:29:27 +00:00
phoglund
c6c00b32da Revert of Remove the rtc_relative_path GYP variable and similar defines (patchset #1 id:1 of https://codereview.webrtc.org/1925733002/ )
Reason for revert:
Breaks downstream gtest usage.

Original issue's description:
> Remove the rtc_relative_path GYP variable and similar defines
>
> This is a reland of https://codereview.webrtc.org/1903553003/ but with
> the SRTP changes removed, since they're needed downstream.
>
> The defines that can be used to alter the include paths for Expat and gtest
> are no longer needed in WebRTC or Chromium. Remove them to simplify GYP.
>
> Removed defines:
> EXPAT_RELATIVE_PATH
> GTEST_RELATIVE_PATH
>
> They're all set in the Chromium build so this shouldn't affect Chromium:
> https://code.google.com/p/chromium/codesearch#chromium/src/third_party/libjingle/libjingle.gyp
>
> BUG=webrtc:4256
> NOTRY=True
> NOPRESUBMIT=True
> TBR=perkj@webrtc.org
>
> Committed: https://crrev.com/081254f2c62037d016f9fc961764c6f01cb095da
> Cr-Commit-Position: refs/heads/master@{#12536}

TBR=perkj@webrtc.org,kjellander@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:4256

Review-Url: https://codereview.webrtc.org/1945803003
Cr-Commit-Position: refs/heads/master@{#12622}
2016-05-04 08:54:39 +00:00
nisse
1bffc1d1a4 Rename rtc::Time64 --> rtc::TimeMillis.
In the discussion on https://codereview.webrtc.org/1888593004/, a more
decriptive name was suggested for Time64.

BUG=webrtc:5740

Review-Url: https://codereview.webrtc.org/1923213002
Cr-Commit-Position: refs/heads/master@{#12594}
2016-05-02 15:19:00 +00:00
henrika
7d4a6c3208 Adds timeout for audio record thread in Java layer
BUG=b/28448866
R=magjed@webrtc.org

Review URL: https://codereview.webrtc.org/1933123002 .

Cr-Commit-Position: refs/heads/master@{#12590}
2016-05-02 09:01:02 +00:00
kwiberg
bfefb03ec1 Replace scoped_ptr with unique_ptr everywhere
But keep #including scoped_ptr.h in .h files, so as not to break
WebRTC users who expect those .h files to give them rtc::scoped_ptr.

BUG=webrtc:5520

Review-Url: https://codereview.webrtc.org/1937693002
Cr-Commit-Position: refs/heads/master@{#12581}
2016-05-01 21:53:55 +00:00
mikescarlett
e7748674ee Allow TransportController to create a QuicTransportChannel
A QuicTransport is implemented that subclasses Transport
and takes ownership of the QuicTransportChannel/P2PTransportChannel.

Split from CL https://codereview.webrtc.org/1844803002/.

BUG=

Review-Url: https://codereview.webrtc.org/1856943002
Cr-Commit-Position: refs/heads/master@{#12575}
2016-04-30 03:21:04 +00:00
Karl Wiberg
0bdebd4b21 Re-add a (dummy) webrtc/base/buffer.cc to hopefully unbreak the Chromium build
Remove this file once Chromium doesn't need it anymore.

TBR=tommi@webrtc.org

BUG=webrtc:5845

Review URL: https://codereview.webrtc.org/1928633006 .

Cr-Commit-Position: refs/heads/master@{#12568}
2016-04-29 18:18:55 +00:00