summaryrefslogtreecommitdiff
path: root/rt/html/NoAuth/images/autohandler
diff options
context:
space:
mode:
authorcvs2git <cvs2git>2009-12-31 13:16:42 +0000
committercvs2git <cvs2git>2009-12-31 13:16:42 +0000
commit36c9e61195cb2cf28dcc3913cdfe4f565a6c836a (patch)
tree2a37ea5e5f696e00093e97f30720c181e79afbe8 /rt/html/NoAuth/images/autohandler
parentb4b0c7e72d7eaee2fbfc7022022c9698323203dd (diff)
This commit was manufactured by cvs2svn to create tag 'RT_3_8_7'.RT_3_8_7
Diffstat (limited to 'rt/html/NoAuth/images/autohandler')
-rw-r--r--rt/html/NoAuth/images/autohandler28
1 files changed, 0 insertions, 28 deletions
diff --git a/rt/html/NoAuth/images/autohandler b/rt/html/NoAuth/images/autohandler
deleted file mode 100644
index 720979830..000000000
--- a/rt/html/NoAuth/images/autohandler
+++ /dev/null
@@ -1,28 +0,0 @@
-<%INIT>
-&RT::Interface::Web::StaticFileHeaders();
-
-# This autohandler will spit out RT's images if the user hasn't
-# properly configured their webserver to stop RT from passing
-# images through the mason handler.
-my $file = $m->base_comp->source_file;
-
-
-my $type = "application/octet-stream";
-if ($file =~ /\.(gif|png|jpe?g)$/i) {
- $type = "image/$1";
- $type =~ s/jpg/jpeg/gi;
-}
-
-die "file not found" unless -f $file && -r _;
-
-$r->content_type($type);
-open my $fh, "<$file" or die "couldn't open file: $!";
-binmode($fh);
-{
- local $/ = \16384;
- $m->out($_) while (<$fh>);
- $m->flush_buffer;
-}
-close $fh;
-$m->abort;
-</%INIT>