Changeset 23666

Show
Ignore:
Timestamp:
11/14/08 17:26:53 (5 years ago)
Author:
tokuhirom
Message:

r30520@skinny: tokuhirom | 2008-11-14 15:55:32 +0900
utf8_heavy 対策

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/perl/MENTA/trunk/lib/MENTA.pm

    r23663 r23666  
    129129            print "status: 404\r\ncontent-type: text/plain\r\n\r\n"; 
    130130        } else { 
    131             die "$path を処理する方法がわかりません"; 
     131            die "${path} を処理する方法がわかりません"; 
    132132        } 
    133133    }; 
    134134    if (my $err = $@) { 
    135         die "エラー処理失敗: $err" unless ref $err eq 'HASH'; 
     135        die "エラー処理失敗: ${err}" unless ref $err eq 'HASH'; 
    136136        return if $err->{finished}; 
    137137 
     
    145145            if ($config->{menta}->{kcatch_mode}) { 
    146146                my $msg = escape_html($err->{message}); 
    147                 my $out = qq{<!doctype html><head><title>500 Internal Server Error</title><style type="text/css">body { margin: 0; padding: 0; background: rgb(230, 230, 230); color: rgb(44, 44, 44); } h1 { margin: 0 0 .5em; padding: .25em; border: 0 none; border-bottom: medium solid rgb(0, 0, 15); background: rgb(63, 63, 63); color: rgb(239, 239, 239); font-size: x-large; } p { margin: .5em 1em; } li { font-size: small; } pre { background: rgb(255, 239, 239); color: rgb(47, 47, 47); font-size: medium; } pre code strong { color: rgb(0, 0, 0); background: rgb(255, 143, 143); } p.f { text-align: right; font-size: xx-small; } p.f span { font-size: medium; }</style></head><h1>500 Internal Server Error</h1><p>$msg</p><ol>}; 
     147                my $out = qq{<!doctype html><title>INTERNAL SERVER ERROR!!! HACKED BY MENTA</title><body style="background: red; color: white; font-weight: bold"><marquee behavior="alternate" scrolldelay="66" style="text-transform: uppercase"><span style="font-size: xx-large; color: black">&#x2620;</span> <span style="color: green">500</span> Internal Server Error <span style="font-size: xx-large; color: black">&#x2620;</span></marquee><p><span style="color: blue">${msg}</span></p><ol>}; 
    148148                for my $stack (@{$err->{trace}}) { 
    149149                    $out .= '<li>' . escape_html(join(', ', $stack->{package}, $stack->{filename}, $stack->{line}))