nsCRT::memset(attachments, 0, sizeof(nsMsgAttachmentData) * attachCount);
memset(attachments, 0, sizeof(nsMsgAttachmentData) * attachCount);
BuildURLAttachmentData(nsIURI *url){  int                 attachCount = 2;  // one entry and one empty entry  nsMsgAttachmentData *attachments = nsnull;  char                *theName = nsnull;  nsXPIDLCString spec;  if (!url)    return nsnull;      attachments = (nsMsgAttachmentData *) PR_Malloc(sizeof(nsMsgAttachmentData) * attachCount);  if (!attachments)    return nsnull;  // Now get a readable name...  url->GetSpec(getter_Copies(spec));  if (spec)  {    theName = PL_strrchr(spec, '/');  }  if (!theName)    theName = "Unknown"; // Don't I18N this string...should never happen...  else    theName++;  nsCRT::memset(attachments, 0, sizeof(nsMsgAttachmentData) * attachCount);  attachments[0].url = url; // The URL to attach. This should be 0 to signify "end of list".  attachments[0].real_name = (char *)PL_strdup(theName);  // The original name of this document, which will eventually show up in the   NS_IF_ADDREF(url);  return attachments;}