From 8f5ee5bea90dfe4b43815d68327e5a738c58c8de Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Wed, 8 Jul 2020 09:16:33 -0400 Subject: [PATCH] TT#84804 test lib: don't require object when not necessary Change-Id: Ib04abee2a1a332fe7d7fc39464b1c09fc4cb9f2b --- perl/NGCP/Rtpclient/ICE.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/perl/NGCP/Rtpclient/ICE.pm b/perl/NGCP/Rtpclient/ICE.pm index 10eb5fbb0..924f3e952 100644 --- a/perl/NGCP/Rtpclient/ICE.pm +++ b/perl/NGCP/Rtpclient/ICE.pm @@ -435,8 +435,8 @@ sub do_input { if ($response) { # construct and send response packet - $self->integrity($response->{attrs}, $response->{mtype}, $tid, $self->{my_pwd}); - $self->fingerprint($response->{attrs}, $response->{mtype}, $tid); + integrity($response->{attrs}, $response->{mtype}, $tid, $self->{my_pwd}); + fingerprint($response->{attrs}, $response->{mtype}, $tid); # XXX unify my $packet = join('', @{$response->{attrs}}); @@ -638,7 +638,7 @@ sub check_to_nominate { } sub integrity { - my ($self, $attrs, $mtype, $tid, $pwd) = @_; + my ($attrs, $mtype, $tid, $pwd) = @_; my $int_check = join('', @$attrs); $int_check = pack('nnNa12', $mtype, length($int_check) + 24, 0x2112A442, $tid) . $int_check; @@ -647,7 +647,7 @@ sub integrity { } sub fingerprint { - my ($self, $attrs, $mtype, $tid) = @_; + my ($attrs, $mtype, $tid) = @_; my $fp_check = join('', @$attrs); $fp_check = pack('nnNa12', $mtype, length($fp_check) + 8, 0x2112A442, $tid) . $fp_check; @@ -928,8 +928,8 @@ sub send_check { $self->{nominate} and unshift(@$attrs, NGCP::Rtpclient::ICE::attr(0x0025, '')); - $self->{agent}->integrity($attrs, 1, $self->{transaction}, $self->{agent}->{other_pwd}); - $self->{agent}->fingerprint($attrs, 1, $self->{transaction}); + integrity($attrs, 1, $self->{transaction}, $self->{agent}->{other_pwd}); + fingerprint($attrs, 1, $self->{transaction}); my $packet = join('', @$attrs); $packet = pack('nnNa12', 1, length($packet), 0x2112A442, $self->{transaction}) . $packet;