diff options
author | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2007-04-10 01:49:16 +0000 |
---|---|---|
committer | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2007-04-10 01:49:16 +0000 |
commit | 13c7a51f1f4b2f809681c4e2651bf0d3992a863e (patch) | |
tree | c37c0217b78996c694d73425b00f3ffa6a55f43e /IkiWiki.pm | |
parent | 15d61ff4ed5991badea8f817f5b858c5588a2ea5 (diff) | |
download | ikiwiki-13c7a51f1f4b2f809681c4e2651bf0d3992a863e.tar ikiwiki-13c7a51f1f4b2f809681c4e2651bf0d3992a863e.tar.gz |
* Optimise displaytime, trimming maybe 6% off the build time.
Diffstat (limited to 'IkiWiki.pm')
-rw-r--r-- | IkiWiki.pm | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm index a6bfddab0..331300db0 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -6,6 +6,7 @@ use strict; use Encode; use HTML::Entities; use URI::Escape q{uri_escape_utf8}; +use POSIX; use open qw{:utf8 :std}; use vars qw{%config %links %oldlinks %pagemtime %pagectime %pagecase @@ -83,8 +84,6 @@ sub checkconfig () { #{{{ delete $ENV{LC_ALL}; } if (defined $config{locale}) { - eval q{use POSIX}; - error($@) if $@; if (POSIX::setlocale(&POSIX::LC_ALL, $config{locale})) { $ENV{LANG}=$config{locale}; $gettext_obj=undef; @@ -434,8 +433,6 @@ sub abs2rel ($$) { #{{{ sub displaytime ($) { #{{{ my $time=shift; - eval q{use POSIX}; - error($@) if $@; # strftime doesn't know about encodings, so make sure # its output is properly treated as utf8 return decode_utf8(POSIX::strftime( |