Ticket #6071: perl-bindings-airdate.patch

File perl-bindings-airdate.patch, 829 bytes (added by otto at kolsi dot fi, 15 years ago)
  • bindings/perl/MythTV/Program.pm

    old new package MythTV::Program; 
    301301        $epminute = "0$epminute" if ($epminute < 10);
    302302        $epsecond = "0$epsecond" if ($epsecond < 10);
    303303    # Original airdate
    304         my ($oyear, $omonth, $oday) = split('-', $self->{'airdate'}, 3);
     304        if($self->{'airdate'}) {
     305            my ($oyear, $omonth, $oday) = split('-', $self->{'airdate'}, 3);
     306        }
     307        else {
     308            $oyear = "0000";
     309            $omonth = "00";
     310            $oday = "00";
     311        }
    305312    # Build a list of name format options
    306313        my %fields;
    307314        ($fields{'T'} = ($self->{'title'}       or '')) =~ s/%/%%/g;