This file is indexed.

/usr/share/perl5/Template/Plugin/UTF8Decode.pm is in libtemplate-plugin-utf8decode-perl 0.01-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package Template::Plugin::UTF8Decode;

use 5.006;
use strict;

our $VERSION = '0.01';

my $FILTER_NAME = 'utf8_decode';

use Template::Plugin::Filter;
use base qw( Template::Plugin::Filter );

sub init {
    my $self = shift;

    $self->install_filter($FILTER_NAME);

    return $self;
}
   
sub filter {
    my ($self, $text) = @_;
    
    utf8::decode($text);
    
    return $text;
}

1;

__END__

=head1 NAME

Template::Plugin::UTF8Decode - UTF8 decoder filter for Template Toolkit

=head1 SYNOPSIS

  [% USE UTF8Decode %]

  [% ansi_string_var | utf8_decode | html_entity %]

=head1 DESCRIPTION

This module is a Template Toolkit filter, which decode a string to utf8.
For example, using FreeTDS (http://www.freetds.org) in order to talk with ms sql, can return an utf8 string
as byte char.

=head1 METHODS

=head2 init

Installs the filter as 'utf8_decode'.

=head2 filter

Receives a reference to the plugin object, along with the text to be
filtered.

=head1 AUTHOR

Fabio Masini E<lt>fabio.masini@gmail.comE<gt>

=head1 COPYRIGHT AND LICENSE

Copyright (C) 2009 Fabio Masini

This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself.

=cut