summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-10-18 20:50:46 +0000
committerThierry Vignaud <tv@mageia.org>2012-10-18 20:50:46 +0000
commitb9626dc4aaf5dfce1b8cf01dee5facb4b5791df8 (patch)
tree52e617ab3c7e8667df5af4fa2864c4d0b3ad594a
parent9e1b1f92fd64c8a148d523a0bdeb675b596b4d33 (diff)
downloaddrakwizard-b9626dc4aaf5dfce1b8cf01dee5facb4b5791df8.tar
drakwizard-b9626dc4aaf5dfce1b8cf01dee5facb4b5791df8.tar.gz
drakwizard-b9626dc4aaf5dfce1b8cf01dee5facb4b5791df8.tar.bz2
drakwizard-b9626dc4aaf5dfce1b8cf01dee5facb4b5791df8.tar.xz
drakwizard-b9626dc4aaf5dfce1b8cf01dee5facb4b5791df8.zip
style: '}' just before 'else/elsif'
-rwxr-xr-xdhcp_wizard/Dhcp.pm20
-rw-r--r--dns_wizard/Bind.pm16
-rwxr-xr-xftp_wizard/Proftpd.pm3
-rw-r--r--pxe_wizard/Pxe.pm14
-rwxr-xr-xsshd_wizard/Sshd.pm7
-rwxr-xr-xweb_wizard/Apache.pm3
6 files changed, 40 insertions, 23 deletions
diff --git a/dhcp_wizard/Dhcp.pm b/dhcp_wizard/Dhcp.pm
index 72a413f1..055dd055 100755
--- a/dhcp_wizard/Dhcp.pm
+++ b/dhcp_wizard/Dhcp.pm
@@ -142,18 +142,26 @@ $o->{pages} = {
sub compute_range {
my ($d, $s) = @_;
my $n;
- if ($d <= 64) { $n = "65" }
- elsif ($d <= 128) { $n = "129" }
- else { $n = "1" }
+ if ($d <= 64) {
+ $n = "65";
+ } elsif ($d <= 128) {
+ $n = "129";
+ } else {
+ $n = "1";
+ }
"$s.$n";
}
sub compute_range2 {
my ($d, $s) = @_;
my $n;
- if ($d <= 128) { $n = "254" }
- elsif ($d > 192) { $n = "192" }
- else { $n = "128" }
+ if ($d <= 128) {
+ $n = "254";
+ } elsif ($d > 192) {
+ $n = "192";
+ } else {
+ $n = "128";
+ }
"$s.$n";
}
diff --git a/dns_wizard/Bind.pm b/dns_wizard/Bind.pm
index 3bd71e8b..4f71f299 100644
--- a/dns_wizard/Bind.pm
+++ b/dns_wizard/Bind.pm
@@ -108,12 +108,16 @@ $o->{pages} = {
},
post => sub {
if ($o->{var}{wiz_level} == 2) {
- return 'slave' }
- elsif ($o->{var}{wiz_level} == 1) {
- return 'interface' }
- elsif ($o->{var}{wiz_level} == 3) {
- if (-f $sys_wizard_dns) { return 'addhost' } else { return 'error_notmaster' } }
- elsif ($o->{var}{wiz_level} == 4) {
+ return 'slave';
+ } elsif ($o->{var}{wiz_level} == 1) {
+ return 'interface';
+ } elsif ($o->{var}{wiz_level} == 3) {
+ if (-f $sys_wizard_dns) {
+ return 'addhost';
+ } else {
+ return 'error_notmaster';
+ }
+ } elsif ($o->{var}{wiz_level} == 4) {
if (-f $sys_wizard_dns) { return 'removehost' } else { return 'error_notmaster' } }
},
data => [
diff --git a/ftp_wizard/Proftpd.pm b/ftp_wizard/Proftpd.pm
index 24f867ae..b2afda55 100755
--- a/ftp_wizard/Proftpd.pm
+++ b/ftp_wizard/Proftpd.pm
@@ -260,8 +260,7 @@ sub do_it {
if ($wiz_ftp_internal && !$wiz_ftp_external) {
($allow) = $wiz->{net}->itf_get("IPADDR") =~ /^(\d{1,3}\.\d{1,3}\.\d{1,3}\.)\d{1,3}$/;
$allow .= " 127.0.0.1";
- }
- elsif ($wiz_ftp_external) {
+ } elsif ($wiz_ftp_external) {
$allow = "all";
}
diff --git a/pxe_wizard/Pxe.pm b/pxe_wizard/Pxe.pm
index fb12ac5d..04c85572 100644
--- a/pxe_wizard/Pxe.pm
+++ b/pxe_wizard/Pxe.pm
@@ -114,11 +114,17 @@ $o->{pages} = {
},
post => sub {
if (! -f "$X86/drakwizard_pxe") { return 'pxeserver' }
- if ($o->{var}{wiz_level} == 1) { return 'pxeserver' }
- elsif ($o->{var}{wiz_level} == 4) { return 'addimgrdz' }
+ if ($o->{var}{wiz_level} == 1) {
+ return 'pxeserver';
+ } elsif ($o->{var}{wiz_level} == 4) {
+ return 'addimgrdz';
+ }
@list_menu or return 'needimg';
- if ($o->{var}{wiz_level} == 2) { return 'removeimg' }
- elsif ($o->{var}{wiz_level} == 3) { return 'modifyimg' }
+ if ($o->{var}{wiz_level} == 2) {
+ return 'removeimg';
+ } elsif ($o->{var}{wiz_level} == 3) {
+ return 'modifyimg';
+ }
},
data => [
{ label => N("What do you want to do:"), val => \$o->{var}{wiz_level}, list => [ keys %level ], format => sub { $level{$_[0]} } },
diff --git a/sshd_wizard/Sshd.pm b/sshd_wizard/Sshd.pm
index cac703d8..99c524cd 100755
--- a/sshd_wizard/Sshd.pm
+++ b/sshd_wizard/Sshd.pm
@@ -96,9 +96,10 @@ $o->{pages} = {
},
post => sub {
if ($o->{var}{wiz_type} == 2) {
- return 'auth_options' }
- elsif ($o->{var}{wiz_type} == 1) {
- return 'summary' }
+ return 'auth_options';
+ } elsif ($o->{var}{wiz_type} == 1) {
+ return 'summary';
+ }
},
next => 'auth_options',
},
diff --git a/web_wizard/Apache.pm b/web_wizard/Apache.pm
index 8fea5014..79395930 100755
--- a/web_wizard/Apache.pm
+++ b/web_wizard/Apache.pm
@@ -258,8 +258,7 @@ sub do_it {
my $that = "localhost";
if ($o->{var}{web_external} eq "1") {
$that = "all";
- }
- elsif ($o->{var}{web_internal} eq "1") {
+ } elsif ($o->{var}{web_internal} eq "1") {
($that) = $wiz->{net}->itf_get("IPADDR") =~ /^(\d{1,3}\.\d{1,3}\.\d{1,3}\.)\d{1,3}$/;
$that .= " 127.0.0.1";
}