diff options
author | Thierry Vignaud <tv@mandriva.org> | 2010-02-25 13:43:15 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2010-02-25 13:43:15 +0000 |
commit | 7b158a9ef528fcdb68b7514961beb5733d140502 (patch) | |
tree | a2369be23a12aaf627cca9cae7b8dfe8895cce3e /perl-install/standalone/drakclock | |
parent | 375f47c50a51b1bb3e6a61b214c511cd224c14d7 (diff) | |
download | drakx-backup-do-not-use-7b158a9ef528fcdb68b7514961beb5733d140502.tar drakx-backup-do-not-use-7b158a9ef528fcdb68b7514961beb5733d140502.tar.gz drakx-backup-do-not-use-7b158a9ef528fcdb68b7514961beb5733d140502.tar.bz2 drakx-backup-do-not-use-7b158a9ef528fcdb68b7514961beb5733d140502.tar.xz drakx-backup-do-not-use-7b158a9ef528fcdb68b7514961beb5733d140502.zip |
prevent forking useless shells
Diffstat (limited to 'perl-install/standalone/drakclock')
-rwxr-xr-x | perl-install/standalone/drakclock | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/perl-install/standalone/drakclock b/perl-install/standalone/drakclock index d9d046a66..ad7378aea 100755 --- a/perl-install/standalone/drakclock +++ b/perl-install/standalone/drakclock @@ -112,13 +112,13 @@ $my_win->{window}->add(gtknew('VBox', border_width => $::isEmbedded ? 0 : 5, chi return; } timezone::set_ntp_server($choosed_serv); - system("/sbin/chkconfig --level 35 ntpd on"); - system("service ntpd stop"); + system(qw(/sbin/chkconfig --level 35 ntpd on)); + system(qw(service ntpd stop)); #verify that we have a valid hostname (thx sam) $choosed_serv =~ s/[^-a-zA-Z0-9.]//g; if (!system("/usr/sbin/ntpdate", $choosed_serv)) { update_time(); #- get the new time before updating the hwclock - system("service ntpd start"); + system(qw(service ntpd start)); $need_date = 0; } else { $in->ask_from_no_check({ @@ -130,8 +130,8 @@ $my_win->{window}->add(gtknew('VBox', border_width => $::isEmbedded ? 0 : 5, chi } } else { if (-e $ntpdlock) { - system("service ntpd stop"); - system("/sbin/chkconfig --level 35 ntpd off"); + system(qw(service ntpd stop)); + system(qw(/sbin/chkconfig --level 35 ntpd off)); } } if ($need_date) { @@ -141,9 +141,9 @@ $my_win->{window}->add(gtknew('VBox', border_width => $::isEmbedded ? 0 : 5, chi system("date " . join('', map { print_it0($_) } ($month, $day, $hour, $min, $year)) . '.' . print_it0($sec)); } - -e '/sbin/hwclock' and system('/sbin/hwclock --systohc'); + -e '/sbin/hwclock' and system('/sbin/hwclock', '--systohc'); any::enable_x_screensaver(); - system("dcop kicker Panel restart") if $ENV{DESKTOP} eq 'kde'; + system(qw(dcop kicker Panel restart)) if $ENV{DESKTOP} eq 'kde'; ugtk2->exit(0); }, }, |