diff -Nur -x '*.orig' -x '*.rej' e-smith-ntp-1.16.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/datetime.pm mezzanine_patched_e-smith-ntp-1.16.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/datetime.pm --- e-smith-ntp-1.16.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/datetime.pm 2003-05-09 10:40:44.000000000 -0600 +++ mezzanine_patched_e-smith-ntp-1.16.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/datetime.pm 2007-01-16 08:21:22.000000000 -0700 @@ -367,7 +367,6 @@ # let ntp enable/disable itself as required $self->_performSetTimeserver(); } - $q->param(-name => "wherenext", -value => "Initial"); $q->Delete('ntpServer'); $q->Delete('ntpStatus'); @@ -596,13 +595,6 @@ } #-------------------------------------------------- - # If we get this far, parameters look good and we're ready to go: - #-------------------------------------------------- - - $q->param(-name => "status_message", - -value => $q->p ( $self->localise('UPDATING_CLOCK'))); - - #-------------------------------------------------- # Store time zone in configuration database #-------------------------------------------------- @@ -627,7 +619,7 @@ esmith::util::backgroundCommand(2, "/sbin/e-smith/signal-event","timezone-update",$newdate); - return ''; + return $self->success('UPDATING_CLOCK'); } =pod @@ -658,7 +650,7 @@ { my $self = shift; my $q = $self->{cgi}; - my $msg = $q->param("status_message") || ""; + my $msg; #------------------------------------------------------------ # Verify the arguments and untaint the variables (see Camel @@ -705,9 +697,7 @@ } $conf->get('UnsavedChanges')->set_value($old); - - $msg .= $q->h2($self->localise("SERVER_DISABLED")); - $msg .= $q->p($self->localise('SERVER_DISABLED_DESC')); + $msg = 'SERVER_DISABLED_DESC'; } else # enable service and synch with ntpServer @@ -722,10 +712,7 @@ } else { - $msg .= $q->h2($self->localise('ERR_CHANGING_TS')); - $msg .= $q->p($self->localise('INVALID_NTP_ADDR').$ntpServer); - $q->param(-name => "status_message", -value => $msg); - return ''; + return return $self->error('INVALID_NTP_ADDR'); } #------------------------------------------------------------ @@ -749,26 +736,21 @@ if ($ntpServer !~ /^\s*$/) { - $msg .= $q->h2($self->localise('SETTINGS_CHANGED')); - $msg .= $q->p($self->localise('SYNC_WITH'). - $q->b(" ", $ntpServer)); + $msg = 'SETTINGS_CHANGED'; } else { $rec->set_prop('status', 'disabled'); $rec->set_prop('NTPServer', ''); - $msg .= $q->h2($self->localise('ERR_CHANGING_TS')); - $msg .= $q->p($self->localise("INVALID_NTP_SERVER")); + $msg = 'INVALID_NTP_SERVER'; } } - $q->param(-name => "status_message", -value => $msg); - esmith::util::backgroundCommand(2, "/sbin/e-smith/signal-event", "timeserver-update"); - return ''; + return $self->success($msg); } 1;