summaryrefslogtreecommitdiffstats
path: root/samba_wizard
diff options
context:
space:
mode:
authorAntoine Ginies <aginies@mandriva.com>2005-07-12 06:45:34 +0000
committerAntoine Ginies <aginies@mandriva.com>2005-07-12 06:45:34 +0000
commitbc3d6e2cb80ab1d61b5e210297352d85487a8ccc (patch)
treed43c53d6f1386f737f842155a44cfd2d0478b92f /samba_wizard
parent36bdc5b4d36d03f35a18301364e144cc6be9d3cb (diff)
downloaddrakwizard-bc3d6e2cb80ab1d61b5e210297352d85487a8ccc.tar
drakwizard-bc3d6e2cb80ab1d61b5e210297352d85487a8ccc.tar.gz
drakwizard-bc3d6e2cb80ab1d61b5e210297352d85487a8ccc.tar.bz2
drakwizard-bc3d6e2cb80ab1d61b5e210297352d85487a8ccc.tar.xz
drakwizard-bc3d6e2cb80ab1d61b5e210297352d85487a8ccc.zip
add test of create mask
Diffstat (limited to 'samba_wizard')
-rwxr-xr-xsamba_wizard/Sambashare.pm8
1 files changed, 8 insertions, 0 deletions
diff --git a/samba_wizard/Sambashare.pm b/samba_wizard/Sambashare.pm
index 5dd305e1..07437fea 100755
--- a/samba_wizard/Sambashare.pm
+++ b/samba_wizard/Sambashare.pm
@@ -228,6 +228,11 @@ $o->{pages} = {
{ label => N('default case'), val => \$o->{var}{wiz_share_default_case}, fixed_list => \@scase, help => N('lower or upper') },
{ label => N('preserve case'), val => \$o->{var}{wiz_share_preserve_case}, fixed_list => \@yesorno, help => N('This controls if new filenames are created with the case that the client passes, or if they are forced to be the default case') },
],
+ complete => sub {
+ if ($o->{var}{wiz_share_create_mask} and $o->{var}{wiz_share_create_mask} !~ /\d+/) {
+ $::in->ask_warn(N("Error"), N("Create mask should be a number. ie: 0755.")) and return 1;
+ }
+ },
next => 'summary_modify',
},
add_share => {
@@ -312,6 +317,9 @@ $o->{pages} = {
}
}
} $o->{var}{wiz_addshare_writelist}, $o->{var}{wiz_addshare_readlist};
+ if ($o->{var}{wiz_addshare_createmask} and $o->{var}{wiz_addshare_createmask} !~ /\d+/) {
+ $::in->ask_warn(N("Error"), N("Create mask should be a number. ie: 0755.")) and return 1;
+ }
},
next => 'summary_addshare',
},