const char *commandTag = GetServerCommandTag(); int protocolStringSize = PL_strlen(formatString) + PL_strlen(messageList) + PL_strlen(messageData) + PL_strlen(commandTag) + 1; char *protocolString = (char *) PR_CALLOC( protocolStringSize );
const char *commandTag = GetServerCommandTag(); int protocolStringSize = PL_strlen(formatString) + PL_strlen(messageList.GetBuffer()) + PL_strlen(messageData) + PL_strlen(commandTag) + 1; char *protocolString = (char *) PR_CALLOC( protocolStringSize );
nsImapProtocol::Store(const char * messageList, const char * messageData,                      PRBool idsAreUid){  IncrementCommandTagNumber();      const char *formatString;  if (idsAreUid)      formatString = "%s uid store %s %s\015\012";  else      formatString = "%s store %s %s\015\012";            // we might need to close this mailbox after this  m_closeNeededBeforeSelect = GetDeleteIsMoveToTrash() &&        (PL_strcasestr(messageData, "\\Deleted"));  const char *commandTag = GetServerCommandTag();  int protocolStringSize = PL_strlen(formatString) +        PL_strlen(messageList) + PL_strlen(messageData) +        PL_strlen(commandTag) + 1;  char *protocolString = (char *) PR_CALLOC( protocolStringSize );  if (protocolString)  {    PR_snprintf(protocolString, // string to create                  protocolStringSize, // max size                  formatString, // format string                  commandTag, // command tag                  messageList,                  messageData);          nsresult rv = SendData(protocolString);    if (NS_SUCCEEDED(rv))      ParseIMAPandCheckForNewMail(protocolString);    PR_Free(protocolString);  }  else    HandleMemoryFailure();}