From fdc954022d6ce22a7f566d06623f91f03289c37a Mon Sep 17 00:00:00 2001 From: Yohann Ferreira Date: Thu, 30 Jun 2005 20:02:40 +0000 Subject: Blocking too long login names to attempt connection or registration. (Thanks Usiu) --- src/gui/login.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/gui') diff --git a/src/gui/login.cpp b/src/gui/login.cpp index d69865f8..6c610e1d 100644 --- a/src/gui/login.cpp +++ b/src/gui/login.cpp @@ -167,6 +167,8 @@ void LoginDialog::action(const std::string& eventId) new OkDialog("Error", "Enter a username first"); } else if (user.length() < 4) { new OkDialog("Error", "The username needs to be at least 4 characters"); + } else if (user.length() > LEN_USERNAME -1 ) { + new OkDialog("Error", "The username needs to be less than 25 characters long."); } else { server_login(user + "_M", passField->getText()); close_session(); -- cgit v1.2.3-60-g2f50