Silence Perl warning

Now that warnings are enabled across the board, this code that tries to
print an undef variable emits one.  Silently printing the empty string
achieves the previous behavior.

Author: Álvaro Herrera <alvherre@alvh.no-ip.org>
Reviewed-by: Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
Discussion: https://postgr.es/m/E1jO1VT-0008Qk-TM@gemulon.postgresql.org
This commit is contained in:
Alvaro Herrera 2020-04-13 19:54:09 -04:00
parent bc3087b626
commit e56d717d8a
No known key found for this signature in database
GPG Key ID: 1C20ACB9D5C564AE
1 changed files with 3 additions and 1 deletions

View File

@ -54,7 +54,9 @@ while (<$feat>)
{
print " <entry>$feature_id</entry>\n";
}
print " <entry>" . $feature_packages{$feature_id} . "</entry>\n";
print " <entry>",
defined($feature_packages{$feature_id}) ? $feature_packages{$feature_id} : "",
"</entry>\n";
if ($subfeature_id)
{
print " <entry>$subfeature_name</entry>\n";