From: Andrew Ruthven Date: Sun, 2 Dec 2007 22:53:54 +0000 (+1300) Subject: Be a bit more paranoid about doing substitutions. X-Git-Tag: 0.5.3~4 X-Git-Url: http://git.etc.gen.nz/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bc310a63b0365feaf5234789f4ab379b46b71ebc;p=mythtv-status.git Be a bit more paranoid about doing substitutions. --- diff --git a/bin/mythtv-status b/bin/mythtv-status index 13090a1..15bb6b5 100755 --- a/bin/mythtv-status +++ b/bin/mythtv-status @@ -417,6 +417,11 @@ sub substitute_vars { my $skip = undef; my ($key, $value); while (($key, $value) = (each %{ $vars })) { + if (! defined $value) { + warn "Unable to find any value for $key while looking at $block->{'name'}\n"; + next; + } + $value = wrap(' ', ' ', $value) if $key eq 'NODE_TEXT';