Subject: | lacnic adds a space when concatenating, however other do not |
This patch expands the behavior to match lacnic.
Subject: | 0001-Fix-spaces-in-descr-field.patch |
From f53a49c583561e65e379d4ed77079ccd2b22717f Mon Sep 17 00:00:00 2001
From: "J. Nick Koston" <nick@cpanel.net>
Date: Mon, 26 Jan 2015 21:57:45 -0600
Subject: [PATCH] Fix spaces in descr field
---
modules/Net-Whois-IANA/Net-Whois-IANA/lib/Net/Whois/IANA.pm | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/modules/Net-Whois-IANA/Net-Whois-IANA/lib/Net/Whois/IANA.pm b/modules/Net-Whois-IANA/Net-Whois-IANA/lib/Net/Whois/IANA.pm
index 57cdccb..d656cd5 100644
--- a/modules/Net-Whois-IANA/Net-Whois-IANA/lib/Net/Whois/IANA.pm
+++ b/modules/Net-Whois-IANA/Net-Whois-IANA/lib/Net/Whois/IANA.pm
@@ -267,7 +267,7 @@ sub ripe_read_query ($$) {
s/\s+$//;
my ($field,$value) = split(/:/);
$value =~ s/^\s+//;
- $query{$field} .= $value;
+ $query{lc($field)} .= ( $query{lc($field)} ? ' ' : '') . $value;
last if (/^route/);
}
close $sock;
@@ -331,7 +331,7 @@ sub apnic_read_query ($$) {
%query = ();
$query{fullinfo} = $tmp{fullinfo};
}
- $query{$field} .= $value;
+ $query{lc($field)} .= ( $query{lc($field)} ? ' ' : '') . $value;
}
close $sock;
for (keys %tmp) {
@@ -393,7 +393,7 @@ sub arin_read_query ($$) {
%query = ();
$query{fullinfo} = $tmp{fullinfo};
}
- $query{lc($field)} .= $value;
+ $query{lc($field)} .= ( $query{lc($field)} ? ' ' : '') . $value;
}
close $sock;
$query{orgname} = $query{custname} if defined $query{custname};
@@ -517,7 +517,7 @@ sub afrinic_read_query ($$) {
s/\s+$//;
my ($field,$value) = split(/:/);
$value =~ s/^\s+//;
- $query{$field} .= $value;
+ $query{lc($field)} .= ( $query{lc($field)} ? ' ' : '') . $value;
}
close $sock;
return %query;
--
2.2.0