Revert "TurnCustomizer - an interface for modifying stun messages sent by TurnPort"

This reverts commit b23ed7f1af467a228cbdc63e839cac8856e9df8d.

Reason for revert: Breaks Chromium FYI build

Sample error log:

../../remoting/test/fake_port_allocator.cc:52:7: error: no matching constructor for initialization of 'cricket::BasicPortAllocator'
    : BasicPortAllocator(network_manager, socket_factory),
      ^                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../third_party/webrtc/p2p/client/basicportallocator.h:32:12: note: candidate constructor not viable: requires single argument 'network_manager', but 2 arguments were provided
  explicit BasicPortAllocator(rtc::NetworkManager* network_manager);
           ^
../../third_party/webrtc/p2p/client/basicportallocator.h:27:7: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 2 were provided
class BasicPortAllocator : public PortAllocator {
      ^
../../third_party/webrtc/p2p/client/basicportallocator.h:29:3: note: candidate constructor not viable: requires 3 arguments, but 2 were provided
  BasicPortAllocator(rtc::NetworkManager* network_manager,
  ^
../../third_party/webrtc/p2p/client/basicportallocator.h:33:3: note: candidate constructor not viable: requires 3 arguments, but 2 were provided
  BasicPortAllocator(rtc::NetworkManager* network_manager,
  ^
../../third_party/webrtc/p2p/client/basicportallocator.h:36:3: note: candidate constructor not viable: requires 5 arguments, but 2 were provided
  BasicPortAllocator(rtc::NetworkManager* network_manager,

Original change's description:
> TurnCustomizer - an interface for modifying stun messages sent by TurnPort
> 
> This patch adds an interface that allows modification of stun messages
> sent by TurnPort. A user can inject a TurnCustomizer on the RTCConfig
> and the TurnCustomizer will be invoked by TurnPort before sending
> message. This allows user to e.g add custom attributes as described
> in rtf5389.
> 
> BUG=webrtc:8313
> 
> Change-Id: Ibf5cc10af84c57288f1eb4c578ca064611a769f1
> Reviewed-on: https://webrtc-review.googlesource.com/4781
> Commit-Queue: Jonas Oreland <jonaso@webrtc.org>
> Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
> Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#20197}

TBR=deadbeef@webrtc.org,sakal@webrtc.org,jonaso@webrtc.org

Change-Id: I624efb22f6e3ceac1b2ff8af1ec47e4cfdde9140
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8313
Reviewed-on: https://webrtc-review.googlesource.com/7680
Reviewed-by: Guido Urdaneta <guidou@webrtc.org>
Commit-Queue: Guido Urdaneta <guidou@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20199}
This commit is contained in:
Guido Urdaneta
2017-10-09 09:53:49 +00:00
committed by Commit Bot
parent 59c7db8e12
commit 604427b875
27 changed files with 36 additions and 559 deletions

View File

@ -478,15 +478,6 @@ void JavaToNativeRTCConfiguration(
jmethodID get_max_id =
GetMethodID(jni, j_interval_range_class, "getMax", "()I");
jfieldID j_turn_customizer_type_id = GetFieldID(
jni, j_rtc_config_class, "turnCustomizer", "Lorg/webrtc/TurnCustomizer;");
jobject j_turn_customizer =
GetNullableObjectField(jni, j_rtc_config, j_turn_customizer_type_id);
jclass j_turn_customizer_class = jni->FindClass("org/webrtc/TurnCustomizer");
jfieldID j_native_turn_customizer_id =
GetFieldID(jni, j_turn_customizer_class, "nativeTurnCustomizer", "J");
rtc_config->type = JavaToNativeIceTransportsType(jni, j_ice_transports_type);
rtc_config->bundle_policy = JavaToNativeBundlePolicy(jni, j_bundle_policy);
rtc_config->rtcp_mux_policy =
@ -531,11 +522,6 @@ void JavaToNativeRTCConfiguration(
int max = jni->CallIntMethod(j_ice_regather_interval_range, get_max_id);
rtc_config->ice_regather_interval_range.emplace(min, max);
}
if (!IsNull(jni, j_turn_customizer)) {
rtc_config->turn_customizer = reinterpret_cast<webrtc::TurnCustomizer*>(
GetLongField(jni, j_turn_customizer, j_native_turn_customizer_id));
}
}
void JavaToNativeRtpParameters(JNIEnv* jni,

View File

@ -1,26 +0,0 @@
/*
* Copyright 2017 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
#include "api/turncustomizer.h"
#include "sdk/android/src/jni/jni_helpers.h"
namespace webrtc {
namespace jni {
JNI_FUNCTION_DECLARATION(void,
TurnCustomizer_nativeFreeTurnCustomizer,
JNIEnv* jni,
jclass,
jlong j_turn_customizer_pointer) {
delete reinterpret_cast<TurnCustomizer*>(j_turn_customizer_pointer);
}
} // namespace jni
} // namespace webrtc