Fix Windows strftime reference

This commit is contained in:
fbsanchez 2020-01-28 20:15:53 +01:00
parent 914a796ce1
commit 77863ae150
4 changed files with 4 additions and 0 deletions

View File

@ -118,6 +118,7 @@ use XML::Simple;
use HTML::Entities; use HTML::Entities;
use Time::Local; use Time::Local;
use Time::HiRes qw(time); use Time::HiRes qw(time);
eval "use POSIX::strftime::GNU;1" if ($^O =~ /win/i);
use POSIX qw(strftime); use POSIX qw(strftime);
use threads; use threads;
use threads::shared; use threads::shared;

View File

@ -27,6 +27,7 @@ use Thread::Semaphore;
use Time::Local; use Time::Local;
use XML::Parser::Expat; use XML::Parser::Expat;
use XML::Simple; use XML::Simple;
eval "use POSIX::strftime::GNU;1" if ($^O =~ /win/i);
use POSIX qw(setsid strftime); use POSIX qw(setsid strftime);
use IO::Uncompress::Unzip; use IO::Uncompress::Unzip;
use JSON qw(decode_json); use JSON qw(decode_json);

View File

@ -22,6 +22,7 @@ use Socket qw(inet_ntoa inet_aton);
use File::Copy; use File::Copy;
use Scalar::Util qw(looks_like_number); use Scalar::Util qw(looks_like_number);
use Time::HiRes qw(time); use Time::HiRes qw(time);
eval "use POSIX::strftime::GNU;1" if ($^O =~ /win/i);
use POSIX qw(strftime setsid floor); use POSIX qw(strftime setsid floor);
use MIME::Base64; use MIME::Base64;
use JSON qw(decode_json encode_json); use JSON qw(decode_json encode_json);

View File

@ -19,6 +19,7 @@ package PandoraFMS::Tools;
use warnings; use warnings;
use Time::Local; use Time::Local;
eval "use POSIX::strftime::GNU;1" if ($^O =~ /win/i);
use POSIX qw(setsid strftime); use POSIX qw(setsid strftime);
use POSIX; use POSIX;
use HTML::Entities; use HTML::Entities;