summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS1
-rwxr-xr-xmdkapplet-restricted-helper12
2 files changed, 12 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index b6149204..4fd5f92b 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,7 @@
privileges
- mdkapplet-restricted-helper
o fix banners' titles
+ o prevent typing in empty password or login
o rephrase some strings (explaining what are restricted media)
Version 2.70.1 - 1 December 2008
diff --git a/mdkapplet-restricted-helper b/mdkapplet-restricted-helper
index 7835fd92..2d5a9219 100755
--- a/mdkapplet-restricted-helper
+++ b/mdkapplet-restricted-helper
@@ -84,7 +84,17 @@ sub get_restricted_authentication() {
create_okcancel($w, N("Next"), N("Cancel")),
]);
- $res ? add_restricted_medium($email_w->get_text, $password) : 0;
+ my $email = $email_w->get_text;
+ if ($res) {
+ if ($email && $password) {
+ add_restricted_medium($email, $password);
+ } else {
+ interactive->vnew->ask_warn(N("Error"), N("Password & email cannot be empty."));
+ goto &get_restricted_authentication;
+ }
+ } else {
+ 0;
+ }
}
sub get_from {