X-Git-Url: http://Server1/repobrowser/?p=kiriwrite%2F.git;a=blobdiff_plain;f=cgi-files%2Fkiriwrite.cgi;h=160f0d10d5ba9eb8ef95a762765d5dbf87e5314a;hp=bd59725a3bea2102446ca0d70fd0bc816f009f22;hb=c72938e207f71a44f0661a1e0c335123f3f404e4;hpb=9379933d4d112578e469053a691dfbb4873384f7 diff --git a/cgi-files/kiriwrite.cgi b/cgi-files/kiriwrite.cgi index bd59725..160f0d1 100755 --- a/cgi-files/kiriwrite.cgi +++ b/cgi-files/kiriwrite.cgi @@ -26,12 +26,15 @@ use warnings; # Write warnings to the HTTP Server Log file. use utf8; use CGI qw(header); -use CGI::Carp('fatalsToBrowser'); # Output errors to the browser. use Tie::IxHash; +# This is commented out because it uses a fair bit of CPU usage. + +#use CGI::Carp('fatalsToBrowser'); # Output errors to the browser. + # Declare global variables for Kiriwrite settings and languages. -my ($kiriwrite_config, %kiriwrite_config, $kiriwrite_lang, $kiriwrite_version, %kiriwrite_version, $kiriwrite_env, %kiriwrite_env, $kiriwrite_presmodule, $kiriwrite_dbmodule); +my ($kiriwrite_config, %kiriwrite_config, $kiriwrite_lang, $kiriwrite_version, %kiriwrite_version, $kiriwrite_env, %kiriwrite_env, $kiriwrite_presmodule, $kiriwrite_dbmodule, $xsl); # Setup the version information for Kiriwrite. @@ -75,6 +78,8 @@ sub BEGIN{ "script_filename" => $script_filename, ); + $ENV{XML_SIMPLE_PREFERRED_PARSER} = "XML::Parser"; + } ################################################################################# @@ -10309,10 +10314,6 @@ sub kiriwrite_settings_edit{ my $confirm = $passedoptions->{"Confirm"}; - # Load the required Perl modules. - - my $xsl = XML::Simple->new(); - if (!$confirm){ # If the confirm value is blank, then set the confirm @@ -11300,7 +11301,7 @@ sub kiriwrite_settings_load{ # Load the required Perl modules. use XML::Simple qw(XMLin); - my $xsl = XML::Simple->new(); + $xsl = XML::Simple->new(); # Check if the Kiriwrite configuration file exists before using it and # return an critical error if it doesn't exist.