diff options
author | Petter Reinholdtsen <pere@hungry.com> | 2015-03-11 09:05:43 +0000 |
---|---|---|
committer | Petter Reinholdtsen <pere@hungry.com> | 2015-03-11 09:05:43 +0000 |
commit | a72705995225c1c9485ea1f8e32cb316eea9ae04 (patch) | |
tree | 9d4fd88e12e86d97333c681b021de6ba2050fcf0 | |
parent | a1bd753265af8258744ea682d6504c11221b998c (diff) |
Avoid perl warnings.
-rwxr-xr-x | tools/gen_frikanalen_video.pl | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/gen_frikanalen_video.pl b/tools/gen_frikanalen_video.pl index 1a79e14..d01bd15 100755 --- a/tools/gen_frikanalen_video.pl +++ b/tools/gen_frikanalen_video.pl @@ -134,7 +134,9 @@ sub read_meta { while (<M>) { chomp; my @l = split("=",$_); - $ret->{$l[0]} = $l[1]; + if (defined $l[1]) { + $ret->{$l[0]} = $l[1]; + } } close M; return $ret; @@ -154,7 +156,7 @@ sub break_title { my $cols = 30; my $count = 0 ; my $ln = 0; - my @lines; + my @lines = ('', '', '', ''); my @words = split(" ",$title); foreach my $word (@words) { $count += count_words_n_space($word); |