Version 21.39: Oct 21, 2021 Fixed bug in nicknamed. Reported by Ana Ollarves Reyes.

This commit is contained in:
acanas 2021-10-21 20:33:55 +02:00
parent f29d0eb62d
commit 711f109e57
14 changed files with 138 additions and 171 deletions

View File

@ -230,11 +230,11 @@ static int API_RemoveOldWSKeys (struct soap *soap);
static int API_GetCurrentDegCodFromCurrentCrsCod (void); static int API_GetCurrentDegCodFromCurrentCrsCod (void);
static bool API_GetSomeUsrDataFromUsrCod (struct UsrData *UsrDat,long CrsCod); static bool API_GetSomeUsrDataFromUsrCod (struct UsrData *UsrDat,long CrsCod);
static int API_CheckParamsNewAccount (char *NewNickWithArr, // Input static int API_CheckParamsNewAccount (char *NewNickWithArr, // Input
char NewNickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1], // Output char NewNickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1], // Output
char *NewEmail, // Input-output char *NewEmail, // Input-output
char *NewPlainPassword, // Input char *NewPlainPassword, // Input
char *NewEncryptedPassword); // Output char NewEncryptedPassword[Pwd_BYTES_ENCRYPTED_PASSWORD + 1]); // Output
static int API_WriteSyllabusIntoHTMLBuffer (struct soap *soap, static int API_WriteSyllabusIntoHTMLBuffer (struct soap *soap,
struct Syl_Syllabus *Syllabus, struct Syl_Syllabus *Syllabus,
@ -755,23 +755,28 @@ static int API_CheckParamsNewAccount (char *NewNickWithArr, // Input
char NewNickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1], // Output char NewNickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1], // Output
char *NewEmail, // Input-output char *NewEmail, // Input-output
char *NewPlainPassword, // Input char *NewPlainPassword, // Input
char *NewEncryptedPassword) // Output char NewEncryptedPassword[Pwd_BYTES_ENCRYPTED_PASSWORD + 1]) // Output
{ {
char CopyOfNewNick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
/***** Step 1/3: Check new nickname *****/ /***** Step 1/3: Check new nickname *****/
/* Make a copy without possible starting arrobas */ /* Make a copy without possible starting arrobas */
Str_Copy (NewNickWithoutArr,NewNickWithArr,Nck_MAX_BYTES_NICK_WITHOUT_ARROBA);
if (Nck_CheckIfNickWithArrIsValid (NewNickWithArr)) // If new nickname is valid if (Nck_CheckIfNickWithArrIsValid (NewNickWithArr)) // If new nickname is valid
{ {
/***** Remove arrobas at the beginning *****/ /***** Remove leading arrobas *****/
Str_RemoveLeadingArrobas (NewNickWithoutArr); Str_Copy (CopyOfNewNick,NewNickWithArr,sizeof (CopyOfNewNick) - 1);
Str_RemoveLeadingArrobas (CopyOfNewNick);
/***** Check if the new nickname matches any of the nicknames of other users *****/ /***** Check if the new nickname matches any of the nicknames of other users *****/
if (DB_QueryCOUNT ("can not check if nickname already existed", if (DB_QueryCOUNT ("can not check if nickname already existed",
"SELECT COUNT(*)" "SELECT COUNT(*)"
" FROM usr_nicknames" " FROM usr_nicknames"
" WHERE Nickname='%s'", " WHERE Nickname='%s'", // A nickname of another user is the same that this nickname
NewNickWithoutArr)) // A nickname of another user is the same that this nickname CopyOfNewNick)) // Already without leading arrobas
return API_CHECK_NEW_ACCOUNT_NICKNAME_REGISTERED_BY_ANOTHER_USER; return API_CHECK_NEW_ACCOUNT_NICKNAME_REGISTERED_BY_ANOTHER_USER;
/***** Output value of nickname without leading arrobas *****/
Str_Copy (NewNickWithoutArr,CopyOfNewNick,Nck_MAX_BYTES_NICK_WITHOUT_ARROBA);
} }
else // New nickname is not valid else // New nickname is not valid
return API_CHECK_NEW_ACCOUNT_NICKNAME_NOT_VALID; return API_CHECK_NEW_ACCOUNT_NICKNAME_NOT_VALID;
@ -3567,7 +3572,7 @@ int swad__sendMessage (struct soap *soap,
{ {
int ReturnCode; int ReturnCode;
long ReplyUsrCod = -1L; long ReplyUsrCod = -1L;
char Nickname[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char Nick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
char *Query = NULL; char *Query = NULL;
MYSQL_RES *mysql_res; MYSQL_RES *mysql_res;
MYSQL_ROW row; MYSQL_ROW row;
@ -3656,12 +3661,12 @@ int swad__sendMessage (struct soap *soap,
while (*Ptr) while (*Ptr)
{ {
/* Find next string in text until comma (leading and trailing spaces are removed) */ /* Find next string in text until comma (leading and trailing spaces are removed) */
Str_GetNextStringUntilComma (&Ptr,Nickname,sizeof (Nickname) - 1); Str_GetNextStringUntilComma (&Ptr,Nick,sizeof (Nick) - 1); // With leading arrobas
/* Check if string is a valid nickname */ /* Check if string is a valid nickname */
if (Nck_CheckIfNickWithArrIsValid (Nickname)) // String is a nickname? if (Nck_CheckIfNickWithArrIsValid (Nick)) // String is a nickname (with leading arrobas)?
{ {
Str_RemoveLeadingArrobas (Nickname); Str_RemoveLeadingArrobas (Nick);
/* Check for overflow in query */ /* Check for overflow in query */
if (strlen (Query) + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 32 > if (strlen (Query) + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 32 >
@ -3684,7 +3689,7 @@ int swad__sendMessage (struct soap *soap,
} }
else else
Str_Concat (Query,",'",API_MAX_BYTES_QUERY_RECIPIENTS); Str_Concat (Query,",'",API_MAX_BYTES_QUERY_RECIPIENTS);
Str_Concat (Query,Nickname,API_MAX_BYTES_QUERY_RECIPIENTS); Str_Concat (Query,Nick,API_MAX_BYTES_QUERY_RECIPIENTS); // Leading arrobas already removed
Str_Concat (Query,"'",API_MAX_BYTES_QUERY_RECIPIENTS); Str_Concat (Query,"'",API_MAX_BYTES_QUERY_RECIPIENTS);
} }
} }

View File

@ -377,7 +377,7 @@ static void Acc_ShowFormRequestNewAccountWithParams (const char NewNickWithoutAr
extern const char *Txt_HELP_nickname; extern const char *Txt_HELP_nickname;
extern const char *Txt_HELP_email; extern const char *Txt_HELP_email;
extern const char *Txt_Email; extern const char *Txt_Email;
char NewNickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NewNickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
/***** Begin form to enter some data of the new user *****/ /***** Begin form to enter some data of the new user *****/
Frm_BeginForm (ActCreUsrAcc); Frm_BeginForm (ActCreUsrAcc);
@ -654,41 +654,39 @@ static bool Acc_GetParamsNewAccount (char NewNickWithoutArr[Nck_MAX_BYTES_NICK_W
char NewEmail[Cns_MAX_BYTES_EMAIL_ADDRESS + 1], char NewEmail[Cns_MAX_BYTES_EMAIL_ADDRESS + 1],
char NewEncryptedPassword[Pwd_BYTES_ENCRYPTED_PASSWORD + 1]) char NewEncryptedPassword[Pwd_BYTES_ENCRYPTED_PASSWORD + 1])
{ {
extern const char *Txt_The_nickname_X_had_been_registered_by_another_user; extern const char *Txt_The_nickname_had_been_registered_by_another_user;
extern const char *Txt_The_nickname_entered_X_is_not_valid_; extern const char *Txt_The_nickname_is_not_valid_;
extern const char *Txt_The_email_address_X_had_been_registered_by_another_user; extern const char *Txt_The_email_address_X_had_been_registered_by_another_user;
extern const char *Txt_The_email_address_entered_X_is_not_valid; extern const char *Txt_The_email_address_entered_X_is_not_valid;
char NewNickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NewNick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
char NewPlainPassword[Pwd_MAX_BYTES_PLAIN_PASSWORD + 1]; char NewPlainPassword[Pwd_MAX_BYTES_PLAIN_PASSWORD + 1];
bool Error = false; bool Error = false;
/***** Step 1/3: Get new nickname from form *****/ /***** Step 1/3: Get new nickname from form *****/
Par_GetParToText ("NewNick",NewNickWithArr,sizeof (NewNickWithArr) - 1); Par_GetParToText ("NewNick",NewNick,sizeof (NewNick) - 1);
/* Remove arrobas at the beginning */ /* Remove arrobas at the beginning */
Str_Copy (NewNickWithoutArr,NewNickWithArr,sizeof (NewNickWithArr) - 1); Str_RemoveLeadingArrobas (NewNick);
Str_RemoveLeadingArrobas (NewNickWithoutArr); Str_Copy (NewNickWithoutArr,NewNick,sizeof (NewNick) - 1);
/* Create a new version of the nickname with arroba */ /* Create a new version of the nickname with arroba */
snprintf (NewNickWithArr,sizeof (NewNickWithArr),"@%s", snprintf (NewNick,sizeof (NewNick),"@%s",
NewNickWithoutArr); NewNickWithoutArr);
if (Nck_CheckIfNickWithArrIsValid (NewNickWithArr)) // If new nickname is valid if (Nck_CheckIfNickWithArrIsValid (NewNick)) // If new nickname is valid
{ {
/* Check if the new nickname /* Check if the new nickname
matches any of the nicknames of other users */ matches any of the nicknames of other users */
if (Acc_DB_CheckIfNicknameAlreadyExists (NewNickWithoutArr)) if (Acc_DB_CheckIfNicknameAlreadyExists (NewNickWithoutArr))
{ {
Error = true; Error = true;
Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_X_had_been_registered_by_another_user, Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_had_been_registered_by_another_user);
NewNickWithoutArr);
} }
} }
else // New nickname is not valid else // New nickname is not valid
{ {
Error = true; Error = true;
Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_entered_X_is_not_valid_, Ale_ShowAlert (Ale_WARNING,Txt_The_nickname_is_not_valid_,
NewNickWithArr,
Nck_MIN_CHARS_NICK_WITHOUT_ARROBA, Nck_MIN_CHARS_NICK_WITHOUT_ARROBA,
Nck_MAX_CHARS_NICK_WITHOUT_ARROBA); Nck_MAX_CHARS_NICK_WITHOUT_ARROBA);
} }

View File

@ -156,10 +156,10 @@ void Agd_PutFormLogInToShowUsrAgenda (void)
void Agd_PutParamAgd (void) void Agd_PutParamAgd (void)
{ {
char Nickname[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
snprintf (Nickname,sizeof (Nickname),"@%s",Gbl.Usrs.Other.UsrDat.Nickname); snprintf (NickWithArr,sizeof (NickWithArr),"@%s",Gbl.Usrs.Other.UsrDat.Nickname);
Par_PutHiddenParamString (NULL,"agd",Nickname); Par_PutHiddenParamString (NULL,"agd",NickWithArr);
} }
/*****************************************************************************/ /*****************************************************************************/

View File

@ -602,13 +602,14 @@ TODO: FIX BUG, URGENT! En las fechas como par
TODO: En las encuestas, que los estudiantes no puedan ver los resultados hasta que no finalice el plazo. TODO: En las encuestas, que los estudiantes no puedan ver los resultados hasta que no finalice el plazo.
*/ */
#define Log_PLATFORM_VERSION "SWAD 21.38.1 (2021-10-20)" #define Log_PLATFORM_VERSION "SWAD 21.39 (2021-10-21)"
#define CSS_FILE "swad20.45.css" #define CSS_FILE "swad20.45.css"
#define JS_FILE "swad20.69.1.js" #define JS_FILE "swad20.69.1.js"
/* /*
TODO: Rename CENTRE to CENTER in help wiki. TODO: Rename CENTRE to CENTER in help wiki.
TODO: Rename ASSESSMENT.Announcements to ASSESSMENT.Calls_for_exams TODO: Rename ASSESSMENT.Announcements to ASSESSMENT.Calls_for_exams
Version 21.39: Oct 21, 2021 Fixed bug in nicknamed. Reported by Ana Ollarves Reyes. (320487 lines)
Version 21.38.1: Oct 20, 2021 Queries moved to module swad_survey_database. (320522 lines) Version 21.38.1: Oct 20, 2021 Queries moved to module swad_survey_database. (320522 lines)
Version 21.38: Oct 20, 2021 New module swad_survey_database for database queries related to surveys. (320457 lines) Version 21.38: Oct 20, 2021 New module swad_survey_database for database queries related to surveys. (320457 lines)
Version 21.37.1: Oct 20, 2021 Code refactoring in attendance. (320361 lines) Version 21.37.1: Oct 20, 2021 Code refactoring in attendance. (320361 lines)

View File

@ -677,7 +677,7 @@ static void Msg_WriteFormSubjectAndContentMsgToUsrs (struct Msg_Messages *Messag
static void Msg_PutHiddenParamAnotherRecipient (const struct UsrData *UsrDat) static void Msg_PutHiddenParamAnotherRecipient (const struct UsrData *UsrDat)
{ {
char NickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
snprintf (NickWithArr,sizeof (NickWithArr),"@%s",UsrDat->Nickname); snprintf (NickWithArr,sizeof (NickWithArr),"@%s",UsrDat->Nickname);
Par_PutHiddenParamString (NULL,"OtherRecipients",NickWithArr); Par_PutHiddenParamString (NULL,"OtherRecipients",NickWithArr);

View File

@ -75,7 +75,7 @@ static void Nck_UpdateUsrNick (struct UsrData *UsrDat);
bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr) bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr)
{ {
char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char CopyOfNick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
unsigned Length; unsigned Length;
const char *Ptr; const char *Ptr;
@ -84,18 +84,18 @@ bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr)
return false; return false;
/***** Make a copy of nickname *****/ /***** Make a copy of nickname *****/
Str_Copy (NickWithoutArr,NickWithArr,sizeof (NickWithoutArr) - 1); Str_Copy (CopyOfNick,NickWithArr,sizeof (CopyOfNick) - 1);
Str_RemoveLeadingArrobas (NickWithoutArr); Str_RemoveLeadingArrobas (CopyOfNick);
Length = strlen (NickWithoutArr); Length = strlen (CopyOfNick); // Leading arrobas already removed
/***** A nick (without arroba) must have a number of characters /***** A nick (without arroba) must have a number of characters
Nck_MIN_BYTES_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_BYTES_NICK_WITHOUT_ARROBA *****/ Nck_MIN_CHARS_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_CHARS_NICK_WITHOUT_ARROBA *****/
if (Length < Nck_MIN_BYTES_NICK_WITHOUT_ARROBA || if (Length < Nck_MIN_CHARS_NICK_WITHOUT_ARROBA ||
Length > Nck_MAX_BYTES_NICK_WITHOUT_ARROBA) Length > Nck_MAX_CHARS_NICK_WITHOUT_ARROBA)
return false; return false;
/***** A nick can have digits, letters and '_' *****/ /***** A nick can have digits, letters and '_' *****/
for (Ptr = NickWithoutArr; for (Ptr = CopyOfNick; // Leading arrobas already removed
*Ptr; *Ptr;
Ptr++) Ptr++)
if (!((*Ptr >= 'a' && *Ptr <= 'z') || if (!((*Ptr >= 'a' && *Ptr <= 'z') ||
@ -113,28 +113,24 @@ bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr)
// Nickname may have leading '@' // Nickname may have leading '@'
// Returns true if nickname found in database // Returns true if nickname found in database
long Nck_GetUsrCodFromNickname (const char Nickname[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]) long Nck_GetUsrCodFromNickname (const char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1])
{ {
char NickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char CopyOfNick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1];
/***** Trivial check 1: nickname should be not null *****/ /***** Trivial check 1: nickname should be not null *****/
if (!Nickname) if (!NickWithArr)
return -1L; return -1L;
/***** Trivial check 2: nickname should be not empty *****/ /***** Trivial check 2: nickname should be not empty *****/
if (!Nickname[0]) if (!NickWithArr[0])
return -1L; return -1L;
/***** Make a copy with possible leading arrobas *****/
Str_Copy (NickWithArr,Nickname,sizeof (NickWithArr) - 1);
/***** Remove leading arrobas *****/ /***** Remove leading arrobas *****/
Str_RemoveLeadingArrobas (NickWithArr); Str_Copy (CopyOfNick,NickWithArr,sizeof (CopyOfNick) - 1);
Str_Copy (NickWithoutArr,NickWithArr,sizeof (NickWithoutArr) - 1); Str_RemoveLeadingArrobas (CopyOfNick);
/***** Get user's code from database *****/ /***** Get user's code from database *****/
return Nck_DB_GetUsrCodFromNickname (NickWithoutArr); return Nck_DB_GetUsrCodFromNickname (CopyOfNick);
} }
/*****************************************************************************/ /*****************************************************************************/
@ -179,7 +175,7 @@ static void Nck_ShowFormChangeUsrNickname (bool ItsMe,
unsigned NumNicks; unsigned NumNicks;
unsigned NumNick; unsigned NumNick;
Act_Action_t NextAction; Act_Action_t NextAction;
char NickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
const struct UsrData *UsrDat = (ItsMe ? &Gbl.Usrs.Me.UsrDat : const struct UsrData *UsrDat = (ItsMe ? &Gbl.Usrs.Me.UsrDat :
&Gbl.Usrs.Other.UsrDat); &Gbl.Usrs.Other.UsrDat);
@ -486,54 +482,47 @@ void Nck_UpdateOtherUsrNick (void)
static void Nck_UpdateUsrNick (struct UsrData *UsrDat) static void Nck_UpdateUsrNick (struct UsrData *UsrDat)
{ {
extern const char *Txt_The_nickname_X_matches_the_one_you_had_previously_registered; extern const char *Txt_The_nickname_matches_the_one_you_had_previously_registered;
extern const char *Txt_The_nickname_X_had_been_registered_by_another_user; extern const char *Txt_The_nickname_had_been_registered_by_another_user;
extern const char *Txt_The_nickname_X_has_been_registered_successfully; extern const char *Txt_The_nickname_has_been_registered_successfully;
extern const char *Txt_The_nickname_entered_X_is_not_valid_; extern const char *Txt_The_nickname_is_not_valid_;
char NewNickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NewNick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
char NewNickWithoutArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1];
/***** Get new nickname from form *****/ /***** Get new nickname from form *****/
Par_GetParToText ("NewNick",NewNickWithArr,sizeof (NewNickWithArr) - 1); Par_GetParToText ("NewNick",NewNick,sizeof (NewNick) - 1);
if (Nck_CheckIfNickWithArrIsValid (NewNickWithArr)) // If new nickname is valid
if (Nck_CheckIfNickWithArrIsValid (NewNick)) // If new nickname is valid
{ {
/***** Remove arrobas at the beginning *****/ /***** Remove arrobas at the beginning *****/
Str_Copy (NewNickWithoutArr,NewNickWithArr,sizeof (NewNickWithoutArr) - 1); Str_RemoveLeadingArrobas (NewNick);
Str_RemoveLeadingArrobas (NewNickWithoutArr);
/***** Check if new nickname exists in database *****/ /***** Check if new nickname exists in database *****/
if (!strcmp (UsrDat->Nickname,NewNickWithoutArr)) // User's nickname match exactly the new nickname if (!strcmp (UsrDat->Nickname,NewNick)) // User's nickname match exactly the new nickname
Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID, Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID,
Txt_The_nickname_X_matches_the_one_you_had_previously_registered, Txt_The_nickname_matches_the_one_you_had_previously_registered);
NewNickWithoutArr); else if (strcasecmp (UsrDat->Nickname,NewNick)) // User's nickname does not match, not even case insensitive, the new nickname
else if (strcasecmp (UsrDat->Nickname,NewNickWithoutArr)) // User's nickname does not match, not even case insensitive, the new nickname
{ {
/***** Check if the new nickname matches any of my old nicknames *****/ /***** Check if the new nickname matches any of my old nicknames *****/
if (!Nck_DB_CheckIfNickMatchesAnyUsrNick (UsrDat->UsrCod, if (!Nck_DB_CheckIfNickMatchesAnyUsrNick (UsrDat->UsrCod,NewNick)) // No matches
NewNickWithoutArr)) // No matches
/***** Check if the new nickname matches any of the nicknames of other users *****/ /***** Check if the new nickname matches any of the nicknames of other users *****/
if (Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (UsrDat->UsrCod, if (Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (UsrDat->UsrCod,NewNick)) // A nickname of another user is the same that user's nickname
NewNickWithoutArr)) // A nickname of another user is the same that user's nickname
Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID, Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID,
Txt_The_nickname_X_had_been_registered_by_another_user, Txt_The_nickname_had_been_registered_by_another_user);
NewNickWithoutArr);
} }
if (Ale_GetNumAlerts () == 0) // No problems if (Ale_GetNumAlerts () == 0) // No problems
{ {
// Now we know the new nickname is not already in database // Now we know the new nickname is not already in database
// and is diffent to the current one // and is diffent to the current one
Nck_DB_UpdateNick (UsrDat->UsrCod,NewNickWithoutArr); Nck_DB_UpdateNick (UsrDat->UsrCod,NewNick); // Leading arrobas already removed
Str_Copy (UsrDat->Nickname,NewNickWithoutArr,sizeof (UsrDat->Nickname) - 1); Str_Copy (UsrDat->Nickname,NewNick,sizeof (UsrDat->Nickname) - 1);
Ale_CreateAlert (Ale_SUCCESS,Nck_NICKNAME_SECTION_ID, Ale_CreateAlert (Ale_SUCCESS,Nck_NICKNAME_SECTION_ID,
Txt_The_nickname_X_has_been_registered_successfully, Txt_The_nickname_has_been_registered_successfully);
NewNickWithoutArr);
} }
} }
else // New nickname is not valid else // New nickname is not valid
Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID, Ale_CreateAlert (Ale_WARNING,Nck_NICKNAME_SECTION_ID,
Txt_The_nickname_entered_X_is_not_valid_, Txt_The_nickname_is_not_valid_,
NewNickWithArr,
Nck_MIN_CHARS_NICK_WITHOUT_ARROBA, Nck_MIN_CHARS_NICK_WITHOUT_ARROBA,
Nck_MAX_CHARS_NICK_WITHOUT_ARROBA); Nck_MAX_CHARS_NICK_WITHOUT_ARROBA);
} }

View File

@ -32,11 +32,12 @@
/************************* Public types and constants ************************/ /************************* Public types and constants ************************/
/*****************************************************************************/ /*****************************************************************************/
#define Nck_MIN_CHARS_NICK_WITHOUT_ARROBA 3 #define Nck_MIN_CHARS_NICK_WITHOUT_ARROBA 3 // Example: jim
#define Nck_MIN_BYTES_NICK_WITHOUT_ARROBA Nck_MIN_CHARS_NICK_WITHOUT_ARROBA #define Nck_MAX_CHARS_NICK_WITHOUT_ARROBA 16 // Example: juancarlos_aroja
#define Nck_MAX_CHARS_NICK_WITHOUT_ARROBA 16
#define Nck_MAX_BYTES_NICK_WITHOUT_ARROBA Nck_MAX_CHARS_NICK_WITHOUT_ARROBA #define Nck_MAX_BYTES_NICK_WITHOUT_ARROBA Nck_MAX_CHARS_NICK_WITHOUT_ARROBA
// Several bytes for leading @ because it may come from form
#define Nck_MAX_BYTES_NICK_WITH_ARROBA (Str_MAX_BYTES_PER_CHAR + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA)
/*****************************************************************************/ /*****************************************************************************/
/***************************** Public prototypes *****************************/ /***************************** Public prototypes *****************************/
@ -44,7 +45,7 @@
bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr); bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr);
long Nck_GetUsrCodFromNickname (const char Nickname[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]); long Nck_GetUsrCodFromNickname (const char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1]);
void Nck_ShowFormChangeMyNickname (bool IMustFillNickname); void Nck_ShowFormChangeMyNickname (bool IMustFillNickname);
void Nck_ShowFormChangeOtherUsrNickname (void); void Nck_ShowFormChangeOtherUsrNickname (void);

View File

@ -67,7 +67,7 @@ void Nck_DB_UpdateNick (long UsrCod,const char *NewNickname)
/************** Get user's code of a user from his/her nickname **************/ /************** Get user's code of a user from his/her nickname **************/
/*****************************************************************************/ /*****************************************************************************/
long Nck_DB_GetUsrCodFromNickname (const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]) long Nck_DB_GetUsrCodFromNickname (const char *NickWithoutArr)
{ {
return DB_QuerySELECTCode ("can not get user's code", return DB_QuerySELECTCode ("can not get user's code",
"SELECT usr_nicknames.UsrCod" "SELECT usr_nicknames.UsrCod"
@ -115,7 +115,7 @@ unsigned Nck_DB_GetUsrNicknames (MYSQL_RES **mysql_res,long UsrCod)
/************ Check if nickname matches any of a user's nicknames ************/ /************ Check if nickname matches any of a user's nicknames ************/
/*****************************************************************************/ /*****************************************************************************/
bool Nck_DB_CheckIfNickMatchesAnyUsrNick (long UsrCod,const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]) bool Nck_DB_CheckIfNickMatchesAnyUsrNick (long UsrCod,const char *NickWithoutArr)
{ {
return (DB_QueryCOUNT ("can not check if nickname already existed", return (DB_QueryCOUNT ("can not check if nickname already existed",
"SELECT COUNT(*)" "SELECT COUNT(*)"
@ -130,7 +130,7 @@ bool Nck_DB_CheckIfNickMatchesAnyUsrNick (long UsrCod,const char NickWithoutArr[
/********* Check if nickname matches any of other user's nicknames ***********/ /********* Check if nickname matches any of other user's nicknames ***********/
/*****************************************************************************/ /*****************************************************************************/
bool Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (long UsrCod,const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]) bool Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (long UsrCod,const char *NickWithoutArr)
{ {
return (DB_QueryCOUNT ("can not check if nickname already existed", return (DB_QueryCOUNT ("can not check if nickname already existed",
"SELECT COUNT(*)" "SELECT COUNT(*)"

View File

@ -40,12 +40,12 @@
void Nck_DB_UpdateNick (long UsrCod,const char *NewNickname); void Nck_DB_UpdateNick (long UsrCod,const char *NewNickname);
long Nck_DB_GetUsrCodFromNickname (const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]); long Nck_DB_GetUsrCodFromNickname (const char *NickWithoutArr);
void Nck_DB_GetNicknameFromUsrCod (long UsrCod, void Nck_DB_GetNicknameFromUsrCod (long UsrCod,
char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]); char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]);
unsigned Nck_DB_GetUsrNicknames (MYSQL_RES **mysql_res,long UsrCod); unsigned Nck_DB_GetUsrNicknames (MYSQL_RES **mysql_res,long UsrCod);
bool Nck_DB_CheckIfNickMatchesAnyUsrNick (long UsrCod,const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]); bool Nck_DB_CheckIfNickMatchesAnyUsrNick (long UsrCod,const char *NickWithoutArr);
bool Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (long UsrCod,const char NickWithoutArr[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]); bool Nck_DB_CheckIfNickMatchesAnyOtherUsrsNicks (long UsrCod,const char *NickWithoutArr);
void Nck_DB_RemoveNickname (long UsrCod,const char *Nickname); void Nck_DB_RemoveNickname (long UsrCod,const char *Nickname);
void Nck_DB_RemoveUsrNicknames (long UsrCod); void Nck_DB_RemoveUsrNicknames (long UsrCod);

View File

@ -662,7 +662,7 @@ void Par_GetMainParams (void)
extern const char *The_ThemeId[The_NUM_THEMES]; extern const char *The_ThemeId[The_NUM_THEMES];
extern const char *Ico_IconSetId[Ico_NUM_ICON_SETS]; extern const char *Ico_IconSetId[Ico_NUM_ICON_SETS];
long ActCod; long ActCod;
char Nickname[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char Nick[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
char URL[PATH_MAX + 1]; char URL[PATH_MAX + 1];
char LongStr[Cns_MAX_DECIMAL_DIGITS_LONG + 1]; char LongStr[Cns_MAX_DECIMAL_DIGITS_LONG + 1];
@ -690,13 +690,13 @@ void Par_GetMainParams (void)
/***** Get another user's nickname, if exists /***** Get another user's nickname, if exists
(this nickname is used to go to another user's profile, (this nickname is used to go to another user's profile,
not to get the logged user) *****/ not to get the logged user) *****/
if (Par_GetParToText ("usr",Nickname,sizeof (Nickname) - 1)) if (Par_GetParToText ("usr",Nick,sizeof (Nick) - 1))
{ {
if (Nickname[0]) if (Nick[0])
{ {
/* Set another user's nickname */ /* Set another user's nickname */
Str_RemoveLeadingArrobas (Nickname); Str_RemoveLeadingArrobas (Nick);
Str_Copy (Gbl.Usrs.Other.UsrDat.Nickname,Nickname, // without arroba Str_Copy (Gbl.Usrs.Other.UsrDat.Nickname,Nick, // Leading arrobas already removed
sizeof (Gbl.Usrs.Other.UsrDat.Nickname) - 1); sizeof (Gbl.Usrs.Other.UsrDat.Nickname) - 1);
// This user's code is used to go to public profile // This user's code is used to go to public profile
@ -706,13 +706,13 @@ void Par_GetMainParams (void)
Gbl.Action.Act = Gbl.Action.Original = ActSeeOthPubPrf; // Set default action if no other is specified Gbl.Action.Act = Gbl.Action.Original = ActSeeOthPubPrf; // Set default action if no other is specified
} }
} }
else if (Par_GetParToText ("agd",Nickname,sizeof (Nickname) - 1)) else if (Par_GetParToText ("agd",Nick,sizeof (Nick) - 1))
{ {
if (Nickname[0]) if (Nick[0])
{ {
/* Set another user's nickname */ /* Set another user's nickname */
Str_RemoveLeadingArrobas (Nickname); Str_RemoveLeadingArrobas (Nick);
Str_Copy (Gbl.Usrs.Other.UsrDat.Nickname,Nickname, // without arroba Str_Copy (Gbl.Usrs.Other.UsrDat.Nickname,Nick, // Leading arrobas already removed
sizeof (Gbl.Usrs.Other.UsrDat.Nickname) - 1); sizeof (Gbl.Usrs.Other.UsrDat.Nickname) - 1);
// This user's code is used to go to public agenda // This user's code is used to go to public agenda

View File

@ -192,7 +192,7 @@ void Prf_RequestUserProfile (void)
extern const char *The_ClassFormInBox[The_NUM_THEMES]; extern const char *The_ClassFormInBox[The_NUM_THEMES];
extern const char *Txt_Nickname; extern const char *Txt_Nickname;
extern const char *Txt_Continue; extern const char *Txt_Continue;
char NickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
if (Gbl.Usrs.Me.Logged) if (Gbl.Usrs.Me.Logged)
{ {

View File

@ -292,10 +292,10 @@ void Str_InsertLinks (char *Txt,unsigned long MaxLength,size_t MaxCharsURLOnScre
Links[NumLinks].NumActualBytes = (size_t) (PtrSrc - Links[NumLinks].PtrStart); Links[NumLinks].NumActualBytes = (size_t) (PtrSrc - Links[NumLinks].PtrStart);
/* A nick (without arroba) must have a number of characters /* A nick (without arroba) must have a number of characters
Nck_MIN_BYTES_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_BYTES_NICK_WITHOUT_ARROBA */ Nck_MIN_CHARS_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_CHARS_NICK_WITHOUT_ARROBA */
Length = Links[NumLinks].NumActualBytes - 1; // Do not count the initial @ Length = Links[NumLinks].NumActualBytes - 1; // Do not count the initial @
IsNickname = (Length >= Nck_MIN_BYTES_NICK_WITHOUT_ARROBA && IsNickname = (Length >= Nck_MIN_CHARS_NICK_WITHOUT_ARROBA &&
Length <= Nck_MAX_BYTES_NICK_WITHOUT_ARROBA); Length <= Nck_MAX_CHARS_NICK_WITHOUT_ARROBA);
if (IsNickname) if (IsNickname)
{ {
@ -732,9 +732,9 @@ void Str_AnalyzeTxtAndStoreNotifyEventToMentionedUsrs (long PubCod,const char *T
Nickname.Length = (size_t) (Ptr - Nickname.PtrStart); Nickname.Length = (size_t) (Ptr - Nickname.PtrStart);
/* A nick (without arroba) must have a number of characters /* A nick (without arroba) must have a number of characters
Nck_MIN_BYTES_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_BYTES_NICK_WITHOUT_ARROBA */ Nck_MIN_CHARS_NICK_WITHOUT_ARROBA <= Length <= Nck_MAX_CHARS_NICK_WITHOUT_ARROBA */
IsNickname = (Nickname.Length >= Nck_MIN_BYTES_NICK_WITHOUT_ARROBA && IsNickname = (Nickname.Length >= Nck_MIN_CHARS_NICK_WITHOUT_ARROBA &&
Nickname.Length <= Nck_MAX_BYTES_NICK_WITHOUT_ARROBA); Nickname.Length <= Nck_MAX_CHARS_NICK_WITHOUT_ARROBA);
if (IsNickname) if (IsNickname)
{ {

View File

@ -49239,79 +49239,70 @@ const char *Txt_The_new_logo_is_X = // Warning: it is very important to include
"O novo logotipo &eacute; <strong>%s</strong>."; "O novo logotipo &eacute; <strong>%s</strong>.";
#endif #endif
const char *Txt_The_nickname_X_has_been_registered_successfully = // Warning: it is very important to include %s in the following sentences const char *Txt_The_nickname_has_been_registered_successfully =
#if L==1 // ca #if L==1 // ca
"El apodo <strong>@%s</strong>" "El apodo se ha registrado correctamente."; // Necessita traduccio
" se ha registrado correctamente."; // Necessita traduccio
#elif L==2 // de #elif L==2 // de
"The nickname <strong>@%s</strong>" "The nickname has been registered successfully."; // Need Übersetzung
" has been registered successfully."; // Need Übersetzung
#elif L==3 // en #elif L==3 // en
"The nickname <strong>@%s</strong>" "The nickname has been registered successfully.";
" has been registered successfully.";
#elif L==4 // es #elif L==4 // es
"El apodo <strong>@%s</strong>" "El apodo se ha registrado correctamente.";
" se ha registrado correctamente.";
#elif L==5 // fr #elif L==5 // fr
"The nickname <strong>@%s</strong>" "The nickname has been registered successfully."; // Besoin de traduction
" has been registered successfully."; // Besoin de traduction
#elif L==6 // gn #elif L==6 // gn
"El apodo <strong>@%s</strong>" "El apodo se ha registrado correctamente."; // Okoteve traducción
" se ha registrado correctamente."; // Okoteve traducción
#elif L==7 // it #elif L==7 // it
"Il nome utente <strong>@%s</strong>" "Il nome utente &egrave; stato registrato con successo.";
" &egrave; stato registrato con successo.";
#elif L==8 // pl #elif L==8 // pl
"The nickname <strong>@%s</strong>" "The nickname has been registered successfully."; // Potrzebujesz tlumaczenie
" has been registered successfully."; // Potrzebujesz tlumaczenie
#elif L==9 // pt #elif L==9 // pt
"A alcunha <strong>@%s</strong>" "A alcunha foi registrada com sucesso.";
" foi registrada com sucesso.";
#endif #endif
const char *Txt_The_nickname_entered_X_is_not_valid_ = // Warning: it is very important to include %s and two %u in the following sentences const char *Txt_The_nickname_is_not_valid_ =
#if L==1 // ca #if L==1 // ca
"El apodo <strong>%s</strong> no es v&aacute;lido.<br />" "El apodo no es v&aacute;lido.<br />"
"El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />" "El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />"
"Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z)," "Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z),"
" un d&iacute;gito (0-9) o &quot;_&quot;."; // Necessita traduccio " un d&iacute;gito (0-9) o &quot;_&quot;."; // Necessita traduccio
#elif L==2 // de #elif L==2 // de
"The nickname <strong>%s</strong> is not valid.<br />" "The nickname is not valid.<br />"
"Your nickname must have a length between %u and %u characters (not including the initial @).<br />" "Your nickname must have a length between %u and %u characters (not including the initial @).<br />"
"Each character after initial @ can be a letter (a-z, A-Z)," "Each character after initial @ can be a letter (a-z, A-Z),"
" a digit (0-9) or &quot;_&quot;."; // Need Übersetzung " a digit (0-9) or &quot;_&quot;."; // Need Übersetzung
#elif L==3 // en #elif L==3 // en
"The nickname <strong>%s</strong> is not valid.<br />" "The nickname is not valid.<br />"
"Your nickname must have a length between %u and %u characters (not including the initial @).<br />" "Your nickname must have a length between %u and %u characters (not including the initial @).<br />"
"Each character after initial @ can be a letter (a-z, A-Z)," "Each character after initial @ can be a letter (a-z, A-Z),"
" a digit (0-9) or &quot;_&quot;."; " a digit (0-9) or &quot;_&quot;.";
#elif L==4 // es #elif L==4 // es
"El apodo <strong>%s</strong> no es v&aacute;lido.<br />" "El apodo no es v&aacute;lido.<br />"
"El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />" "El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />"
"Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z)," "Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z),"
" un d&iacute;gito (0-9) o &quot;_&quot;."; " un d&iacute;gito (0-9) o &quot;_&quot;.";
#elif L==5 // fr #elif L==5 // fr
"The nickname <strong>%s</strong> is not valid.<br />" "The nickname is not valid.<br />"
"Your nickname must have a length between %u and %u characters (not including initial the @).<br />" "Your nickname must have a length between %u and %u characters (not including initial the @).<br />"
"Each character after initial @ can be a letter (a-z, A-Z)," "Each character after initial @ can be a letter (a-z, A-Z),"
" a digit (0-9) or &quot;_&quot;."; // Besoin de traduction " a digit (0-9) or &quot;_&quot;."; // Besoin de traduction
#elif L==6 // gn #elif L==6 // gn
"El apodo <strong>%s</strong> no es v&aacute;lido.<br />" "El apodo no es v&aacute;lido.<br />"
"El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />" "El apodo debe tener una longitud entre %u y %u caracteres (sin contar la @ inicial).<br />"
"Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z)," "Cada car&aacute;cter posterior a la @ inicial puede ser una letra (a-z, A-Z),"
" un d&iacute;gito (0-9) o &quot;_&quot;."; // Okoteve traducción " un d&iacute;gito (0-9) o &quot;_&quot;."; // Okoteve traducción
#elif L==7 // it #elif L==7 // it
"Il nome utente <strong>%s</strong> non &egrave; valido.<br />" "Il nome utente non &egrave; valido.<br />"
"Your nickname must have a length between %u and %u characters (not including the initial @).<br /> " "Your nickname must have a length between %u and %u characters (not including the initial @).<br /> "
"Each character after initial @ can be a letter (a-z, A-Z)," "Each character after initial @ can be a letter (a-z, A-Z),"
" a digit (0-9) or &quot;_&quot;."; // Bisogno di traduzione " a digit (0-9) or &quot;_&quot;."; // Bisogno di traduzione
#elif L==8 // pl #elif L==8 // pl
"The nickname <strong>%s</strong> is not valid.<br />" "The nickname is not valid.<br />"
"Your nickname must have a length between %u and %u characters (not including the initial @).<br />" "Your nickname must have a length between %u and %u characters (not including the initial @).<br />"
"Each character after initial @ can be a letter (a-z, A-Z)," "Each character after initial @ can be a letter (a-z, A-Z),"
" a digit (0-9) or &quot;_&quot;."; // Potrzebujesz tlumaczenie " a digit (0-9) or &quot;_&quot;."; // Potrzebujesz tlumaczenie
#elif L==9 // pt #elif L==9 // pt
"A alcunha <strong>%s</strong> n&atilde;o &eacute; v&aacute;lido.<br />" "A alcunha n&atilde;o &eacute; v&aacute;lido.<br />"
"Sua alcunha deve ter um tamanho entre %u e %u caracteres (sem incluir o inicial @).<br />" "Sua alcunha deve ter um tamanho entre %u e %u caracteres (sem incluir o inicial @).<br />"
"Cada caractere ap&oacute;s inicial @ pode ser uma letra (a-z, A-Z)," "Cada caractere ap&oacute;s inicial @ pode ser uma letra (a-z, A-Z),"
" um dígito (0-9) ou &quot;_&quot;."; " um dígito (0-9) ou &quot;_&quot;.";
@ -49503,64 +49494,46 @@ const char *Txt_The_new_URL_is_X = // Warning: it is very important to include %
"O novo URL &eacute; <strong>%s</strong>."; "O novo URL &eacute; <strong>%s</strong>.";
#endif #endif
const char *Txt_The_nickname_X_had_been_registered_by_another_user = // Warning: it is very important to include %s in the following sentences const char *Txt_The_nickname_had_been_registered_by_another_user =
#if L==1 // ca #if L==1 // ca
"El apodo <strong>@%s</strong>" "El apodo ya hab&iacute;a sido registrado por otro usuario."; // Necessita traduccio
" ya hab&iacute;a sido registrado por otro usuario."; // Necessita traduccio
#elif L==2 // de #elif L==2 // de
"The nickname <strong>@%s</strong>" "The nickname had been registered by another user."; // Need Übersetzung
" had been registered by another user."; // Need Übersetzung
#elif L==3 // en #elif L==3 // en
"The nickname <strong>@%s</strong>" "The nickname had been registered by another user.";
" had been registered by another user.";
#elif L==4 // es #elif L==4 // es
"El apodo <strong>@%s</strong>" "El apodo ya hab&iacute;a sido registrado por otro usuario.";
" ya hab&iacute;a sido registrado por otro usuario.";
#elif L==5 // fr #elif L==5 // fr
"The nickname <strong>@%s</strong>" "The nickname had been enroled by another user."; // Besoin de traduction
" had been enroled by another user."; // Besoin de traduction
#elif L==6 // gn #elif L==6 // gn
"El apodo <strong>@%s</strong>" "El apodo ya hab&iacute;a sido registrado por otro usuario."; // Okoteve traducción
" ya hab&iacute;a sido registrado por otro usuario."; // Okoteve traducción
#elif L==7 // it #elif L==7 // it
"Il nome utente <strong>@%s</strong>" "Il nome utente &egrave; stato registrato da un altro utente.";
" &egrave; stato registrato da un altro utente.";
#elif L==8 // pl #elif L==8 // pl
"The nickname <strong>@%s</strong>" "The nickname had been registered by another user."; // Potrzebujesz tlumaczenie
" had been registered by another user."; // Potrzebujesz tlumaczenie
#elif L==9 // pt #elif L==9 // pt
"A alcunha <strong>@%s</strong>" "A alcunha foi registrada por outro usu&aacute;rio.";
" foi registrada por outro usu&aacute;rio.";
#endif #endif
const char *Txt_The_nickname_X_matches_the_one_you_had_previously_registered = // Warning: it is very important to include %s in the following sentences const char *Txt_The_nickname_matches_the_one_you_had_previously_registered =
#if L==1 // ca #if L==1 // ca
"El apodo <strong>@%s</strong>" "El apodo coincide con el que ya ten&iacute;a registrado previamente."; // Necessita traduccio
" coincide con el que ya ten&iacute;a registrado previamente."; // Necessita traduccio
#elif L==2 // de #elif L==2 // de
"The nickname <strong>@%s</strong>" "The nickname matches the one you had previously registered."; // Need Übersetzung
" matches the one you had previously registered."; // Need Übersetzung
#elif L==3 // en #elif L==3 // en
"The nickname <strong>@%s</strong>" "The nickname matches the one you had previously registered.";
" matches the one you had previously registered.";
#elif L==4 // es #elif L==4 // es
"El apodo <strong>@%s</strong>" "El apodo coincide con el que ya ten&iacute;a registrado previamente.";
" coincide con el que ya ten&iacute;a registrado previamente.";
#elif L==5 // fr #elif L==5 // fr
"The nickname <strong>@%s</strong>" "The nickname matches the one you had previously registered."; // Besoin de traduction
" matches the one you had previously registered."; // Besoin de traduction
#elif L==6 // gn #elif L==6 // gn
"El apodo <strong>@%s</strong>" "El apodo coincide con el que ya ten&iacute;a registrado previamente."; // Okoteve traducción
" coincide con el que ya ten&iacute;a registrado previamente."; // Okoteve traducción
#elif L==7 // it #elif L==7 // it
"Il nome utente <strong>@%s</strong>" "Il nome utente coincide con quello che hai precedentemente registrato.";
" coincide con quello che hai precedentemente registrato.";
#elif L==8 // pl #elif L==8 // pl
"The nickname <strong>@%s</strong>" "The nickname matches the one you had previously registered."; // Potrzebujesz tlumaczenie
" matches the one you had previously registered."; // Potrzebujesz tlumaczenie
#elif L==9 // pt #elif L==9 // pt
"A alcunha <strong>@%s</strong>" "A alcunha corresponde &agrave;quela que voc&ecirc; registrou anteriormente.";
" corresponde &agrave;quela que voc&ecirc; registrou anteriormente.";
#endif #endif
const char *Txt_The_number_of_editing_lines_in_the_record_field_X_has_not_changed = // Warning: it is very important to include %s in the following sentences const char *Txt_The_number_of_editing_lines_in_the_record_field_X_has_not_changed = // Warning: it is very important to include %s in the following sentences

View File

@ -10190,7 +10190,7 @@ void Usr_DB_RemoveUsrFromBanned (long UsrCod)
void Usr_PrintUsrQRCode (void) void Usr_PrintUsrQRCode (void)
{ {
char NewNickWithArr[1 + Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]; char NewNickWithArr[Nck_MAX_BYTES_NICK_WITH_ARROBA + 1];
if (Usr_GetParamOtherUsrCodEncryptedAndGetUsrData ()) if (Usr_GetParamOtherUsrCodEncryptedAndGetUsrData ())
{ {