aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/greeter-list.vala7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/greeter-list.vala b/src/greeter-list.vala
index 7fafdcb..5f830da 100644
--- a/src/greeter-list.vala
+++ b/src/greeter-list.vala
@@ -19,6 +19,8 @@
* Scott Sweeny <scott.sweeny@canonical.com>
*/
+private const int MAX_FIELD_SIZE = 200;
+
private int get_grid_offset (int size)
{
return (int) (size % grid_size) / 2;
@@ -808,7 +810,10 @@ public abstract class GreeterList : FadableBox
text = _("Password:");
if (text == "login:")
text = _("Username:");
- add_prompt (text, type == LightDM.PromptType.SECRET);
+ var entry = add_prompt (text, type == LightDM.PromptType.SECRET);
+
+ /* Limit the number of characters in case a cat is sitting on the keyboard... */
+ entry.max_length = MAX_FIELD_SIZE;
}
protected virtual void authentication_complete_cb ()