summaryrefslogtreecommitdiffstats
path: root/lib/ASM
diff options
context:
space:
mode:
authorLibravatarWilliam Heimbigner <william.heimbigner@gmail.com>2016-01-14 21:30:03 -0700
committerLibravatarWilliam Heimbigner <william.heimbigner@gmail.com>2016-01-14 21:30:03 -0700
commite4280f1700c119d69ff58472e215dd68b836416a (patch)
treede0a68bd3baf356aaadbab7cace81fc8c8651339 /lib/ASM
parent005c59b38492606da652d6adda922ee3e821d4e9 (diff)
Fix a bug where part of the DNS routines could be called with an undefined value, and then go kaboom
Diffstat (limited to 'lib/ASM')
-rw-r--r--lib/ASM/Util.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/ASM/Util.pm b/lib/ASM/Util.pm
index 7b910a1..e5ec1d1 100644
--- a/lib/ASM/Util.pm
+++ b/lib/ASM/Util.pm
@@ -239,6 +239,9 @@ sub stripResp
{
my $module = shift;
my $response = shift;
+ if (!defined($response)) {
+ return undef;
+ }
my @answer = $response->answer;
if ($response->{header}->{rcode} ne "NOERROR") {
dprint($module, Dumper($response), 'dns');