Verified Commit c2d76dab authored by ma1's avatar ma1
Browse files

fixup! Bug 1914583 - Block IPAddrAny on H3 code path. r=necko-reviewers,kershaw

Remove glean references.
parent d686ade4
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@

#include "ASpdySession.h"
#include "mozilla/StaticPrefs_network.h"
#include "mozilla/glean/NetwerkMetrics.h"
#include "mozilla/Telemetry.h"
#include "HttpConnectionUDP.h"
#include "nsHttpHandler.h"
@@ -93,16 +92,9 @@ nsresult HttpConnectionUDP::Init(nsHttpConnectionInfo* info,
  // See https://github.com/whatwg/fetch/pull/1763 for context.
  if (peerAddr.IsIPAddrAny()) {
    if (StaticPrefs::network_socket_ip_addr_any_disabled()) {
      mozilla::glean::networking::http_ip_addr_any_count
          .Get("blocked_requests"_ns)
          .Add(1);
      LOG(("Connection refused because of 0.0.0.0 IP address\n"));
      return NS_ERROR_CONNECTION_REFUSED;
    }

    mozilla::glean::networking::http_ip_addr_any_count
        .Get("not_blocked_requests"_ns)
        .Add(1);
  }

  mSocket = do_CreateInstance("@mozilla.org/network/udp-socket;1", &rv);