aPath += NS_LITERAL_CSTRING("subject=Form%20Post%20From%20Mozilla&");
aPath.AppendLiteral("subject=Form%20Post%20From%20Mozilla&");
HandleMailtoSubject(nsCString& aPath) {  // Walk through the string and see if we have a subject already.  PRBool hasSubject = PR_FALSE;  PRBool hasParams = PR_FALSE;  PRInt32 paramSep = aPath.FindChar('?');  while (paramSep != kNotFound && paramSep < (PRInt32)aPath.Length()) {    hasParams = PR_TRUE;    // Get the end of the name at the = op.  If it is *after* the next &,    // assume that someone made a parameter without an = in it    PRInt32 nameEnd = aPath.FindChar('=', paramSep+1);    PRInt32 nextParamSep = aPath.FindChar('&', paramSep+1);    if (nextParamSep == kNotFound) {      nextParamSep = aPath.Length();    }    // If the = op is after the &, this parameter is a name without value.    // If there is no = op, same thing.    if (nameEnd == kNotFound || nextParamSep < nameEnd) {      nameEnd = nextParamSep;    }    if (nameEnd != kNotFound) {      if (Substring(aPath, paramSep+1, nameEnd-(paramSep+1)) ==          NS_LITERAL_CSTRING("subject")) {        hasSubject = PR_TRUE;        break;      }    }    paramSep = nextParamSep;  }  // If there is no subject, append a preformed subject to the mailto line  if (!hasSubject) {    if (hasParams) {      aPath.Append('&');    } else {      aPath.Append('?');    }    aPath += NS_LITERAL_CSTRING("subject=Form%20Post%20From%20Mozilla&");  }}