Use nsCRT::free() instead of delete[] for char* data.

git-svn-id: svn://10.0.0.236/trunk@46092 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bruce%cybersight.com 1999-09-06 06:22:51 +00:00
parent 3951be98b5
commit bf0dde26b0
12 changed files with 71 additions and 72 deletions

View File

@ -76,8 +76,8 @@ NS_IMETHODIMP DeleteElementTxn::Do(void)
{
if (gNoisy)
printf(" DeleteElementTxn: deleting child %s from parent %s\n", c, p);
delete [] c;
delete [] p;
nsCRT::free(c);
nsCRT::free(p);
}
// end debug output
#endif
@ -115,8 +115,8 @@ NS_IMETHODIMP DeleteElementTxn::Undo(void)
{
if (gNoisy)
printf(" DeleteElementTxn: inserting child %s back into parent %s\n", c, p);
delete [] c;
delete [] p;
nsCRT::free(c);
nsCRT::free(p);
}
// end debug output
#endif

View File

@ -377,7 +377,7 @@ nsTextEditorKeyListener::ProcessShortCutKeys(nsIDOMEvent* aKeyEvent, PRBool& aPr
if (buf)
{
puts(buf);
delete[] buf;
nsCRT::free(buf);
}
}
}
@ -781,7 +781,7 @@ nsTextEditorKeyListener::ProcessShortCutKeys(nsIDOMEvent* aKeyEvent, PRBool& aPr
nsString *tag = styles.StringAt(i);
char *tagCString = tag->ToNewCString();
printf("%s ", tagCString);
delete [] tagCString;
nsCRT::free(tagCString);
}
printf("\n");
}
@ -1418,7 +1418,7 @@ nsTextEditorDragListener::DragDrop(nsIDOMEvent* aMouseEvent)
dragSession->SetCanDrop(PR_TRUE);
}
delete [] whichFlavor;
nsCRT::free(whichFlavor);
// XXX This is where image support might go
//void * data;
//trans->GetTransferData(mImageDataFlavor, (void **)&data, &len);

View File

@ -365,7 +365,7 @@ nsEditorShell::InstantiateEditor(nsIDOMDocument *aDoc, nsIPresShell *aPresShell)
errorMsg += "\"\n";
char *errorMsgCString = errorMsg.ToNewCString();
NS_WARNING(errorMsgCString);
delete [] errorMsgCString;
nsCRT::free(errorMsgCString);
#endif
}
@ -869,7 +869,7 @@ nsEditorShell::SetWebShellWindow(nsIDOMWindow* aWin)
char* cstr = str.ToNewCString();
printf("Attaching to WebShellWindow[%s]\n", cstr);
delete[] cstr;
nsCRT::free(cstr);
#endif
nsCOMPtr<nsIWebShellContainer> webShellContainer;
@ -2906,7 +2906,7 @@ void nsEditorShell::SetButtonImage(nsIDOMNode * aParentNode, PRInt32 aBtnNum, co
if (imgElement) {
char * str = aResName.ToNewCString();
imgElement->SetSrc(str);
delete [] str;
nsCRT::free(str);
}
}
@ -2923,7 +2923,7 @@ nsEditorShell::ExecuteScript(nsIScriptContext * aContext, const nsString& aScrip
#ifdef APP_DEBUG
char* script_str = aScript.ToNewCString();
printf("Executing [%s]\n", script_str);
delete[] script_str;
nsCRT::free(script_str);
#endif
aContext->EvaluateString(aScript, url, 0, rVal, &isUndefined);

View File

@ -446,7 +446,7 @@ NS_IMETHODIMP nsHTMLEditor::SetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result=NS_ERROR_NOT_INITIALIZED;
@ -563,7 +563,7 @@ NS_IMETHODIMP nsHTMLEditor::SetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -582,7 +582,7 @@ NS_IMETHODIMP nsHTMLEditor::GetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("nsTextEditor::GetTextProperty %s\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
*/
nsresult result;
@ -700,7 +700,7 @@ NS_IMETHODIMP nsHTMLEditor::RemoveInlineProperty(nsIAtom *aProperty, const nsStr
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::RemoveInlineProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result;
@ -806,7 +806,7 @@ NS_IMETHODIMP nsHTMLEditor::RemoveInlineProperty(nsIAtom *aProperty, const nsStr
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::RemoveInlineProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -1390,7 +1390,7 @@ nsHTMLEditor::AddBlockParent(nsString& aParentTag)
{
char *tag = aParentTag.ToNewCString();
printf("---------- nsHTMLEditor::AddBlockParent %s ----------\n", tag);
delete [] tag;
nsCRT::free(tag);
}
nsresult res=NS_ERROR_NOT_INITIALIZED;
@ -1435,7 +1435,7 @@ nsHTMLEditor::ReplaceBlockParent(nsString& aParentTag)
{
char *tag = aParentTag.ToNewCString();
printf("---------- nsHTMLEditor::ReplaceBlockParent %s ----------\n", tag);
delete [] tag;
nsCRT::free(tag);
}
nsresult res=NS_ERROR_NOT_INITIALIZED;
@ -2608,7 +2608,7 @@ NS_IMETHODIMP nsHTMLEditor::SetBodyWrapWidth(PRInt32 aWrapColumn)
#ifdef DEBUG_akkana
char* curstyle = styleValue.ToNewCString();
printf("Setting style: [%s]\n", curstyle);
delete[] curstyle;
nsCRT::free(curstyle);
#endif /* DEBUG_akkana */
return bodyElement->SetAttribute(styleName, styleValue);
@ -2932,7 +2932,7 @@ NS_IMETHODIMP nsHTMLEditor::Paste()
#ifdef DEBUG_akkana
char* flav = flavor.ToNewCString();
printf("Got flavor [%s]\n", flav);
delete[] flav;
nsCRT::free(flav);
#endif
if (flavor.Equals(kHTMLMime))
{
@ -2965,7 +2965,7 @@ NS_IMETHODIMP nsHTMLEditor::Paste()
rv = NS_ERROR_NOT_IMPLEMENTED; // for now give error code
}
}
delete [] bestFlavor;
nsCRT::free(bestFlavor);
}
}
}
@ -2990,19 +2990,19 @@ NS_IMETHODIMP nsHTMLEditor::OutputToString(nsString& aOutputString,
else
{ // default processing
nsCOMPtr<nsIDocumentEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);
@ -3058,20 +3058,20 @@ NS_IMETHODIMP nsHTMLEditor::OutputToStream(nsIOutputStream* aOutputStream,
{
nsresult rv;
nsCOMPtr<nsIDocumentEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);
@ -3594,7 +3594,7 @@ nsHTMLEditor::ReParentContentOfNode(nsIDOMNode *aNode,
{
char *tag = aParentTag.ToNewCString();
printf("---------- ReParentContentOfNode(%p,%s,%d) -----------\n", aNode, tag, aTransformation);
delete [] tag;
nsCRT::free(tag);
}
// find the current block parent, or just use aNode if it is a block node
nsCOMPtr<nsIDOMElement>blockParentElement;

View File

@ -63,7 +63,7 @@ NS_IMETHODIMP nsInsertHTMLTxn::Do(void)
#ifdef DEBUG_akkana
char* str = mSrc.ToNewCString();
printf("Calling nsInsertHTMLTxn::Do(%s)\n", str);
delete[] str;
nsCRT::free(str);
#endif /* DEBUG_akkana */
nsCOMPtr<nsIDOMDocumentFragment> docfrag;
res = nsrange->CreateContextualFragment(mSrc, getter_AddRefs(docfrag));

View File

@ -629,7 +629,7 @@ nsTextEditRules::WillDeleteSelection(nsIDOMSelection *aSelection,
#ifdef DEBUG_buster
char *password = mPasswordText.ToNewCString();
printf("mPasswordText is %s\n", password);
delete [] password;
nsCRT::free(password);
#endif
}
return NS_OK;
@ -989,7 +989,7 @@ nsTextEditRules::EchoInsertionToPWBuff(nsIDOMSelection *aSelection, nsString *aO
#ifdef DEBUG_jfrancis
char *password = mPasswordText.ToNewCString();
printf("mPasswordText is %s\n", password);
delete [] password;
nsCRT::free(password);
#endif
// change the output to '*' only

View File

@ -394,7 +394,7 @@ NS_IMETHODIMP nsTextEditor::SetTextProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result=NS_ERROR_NOT_INITIALIZED;
@ -510,7 +510,7 @@ NS_IMETHODIMP nsTextEditor::SetTextProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -729,7 +729,7 @@ NS_IMETHODIMP nsTextEditor::RemoveTextProperty(nsIAtom *aProperty, const nsStrin
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::RemoveTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result;
@ -818,7 +818,7 @@ NS_IMETHODIMP nsTextEditor::RemoveTextProperty(nsIAtom *aProperty, const nsStrin
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::RemoveTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -1484,7 +1484,6 @@ NS_IMETHODIMP nsTextEditor::ApplyStyleSheet(const nsString& aURL)
return nsEditor::ApplyStyleSheet(aURL);
}
NS_IMETHODIMP nsTextEditor::OutputToString(nsString& aOutputString,
const nsString& aFormatType,
PRUint32 aFlags)
{
@ -1501,19 +1500,19 @@ NS_IMETHODIMP nsTextEditor::OutputToString(nsString& aOutputString,
else
{ // default processing
nsCOMPtr<nsITextEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);
@ -1576,20 +1575,20 @@ NS_IMETHODIMP nsTextEditor::OutputToStream(nsIOutputStream* aOutputStream,
{
nsresult rv;
nsCOMPtr<nsITextEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);

View File

@ -365,7 +365,7 @@ nsEditorShell::InstantiateEditor(nsIDOMDocument *aDoc, nsIPresShell *aPresShell)
errorMsg += "\"\n";
char *errorMsgCString = errorMsg.ToNewCString();
NS_WARNING(errorMsgCString);
delete [] errorMsgCString;
nsCRT::free(errorMsgCString);
#endif
}
@ -869,7 +869,7 @@ nsEditorShell::SetWebShellWindow(nsIDOMWindow* aWin)
char* cstr = str.ToNewCString();
printf("Attaching to WebShellWindow[%s]\n", cstr);
delete[] cstr;
nsCRT::free(cstr);
#endif
nsCOMPtr<nsIWebShellContainer> webShellContainer;
@ -2906,7 +2906,7 @@ void nsEditorShell::SetButtonImage(nsIDOMNode * aParentNode, PRInt32 aBtnNum, co
if (imgElement) {
char * str = aResName.ToNewCString();
imgElement->SetSrc(str);
delete [] str;
nsCRT::free(str);
}
}
@ -2923,7 +2923,7 @@ nsEditorShell::ExecuteScript(nsIScriptContext * aContext, const nsString& aScrip
#ifdef APP_DEBUG
char* script_str = aScript.ToNewCString();
printf("Executing [%s]\n", script_str);
delete[] script_str;
nsCRT::free(script_str);
#endif
aContext->EvaluateString(aScript, url, 0, rVal, &isUndefined);

View File

@ -76,8 +76,8 @@ NS_IMETHODIMP DeleteElementTxn::Do(void)
{
if (gNoisy)
printf(" DeleteElementTxn: deleting child %s from parent %s\n", c, p);
delete [] c;
delete [] p;
nsCRT::free(c);
nsCRT::free(p);
}
// end debug output
#endif
@ -115,8 +115,8 @@ NS_IMETHODIMP DeleteElementTxn::Undo(void)
{
if (gNoisy)
printf(" DeleteElementTxn: inserting child %s back into parent %s\n", c, p);
delete [] c;
delete [] p;
nsCRT::free(c);
nsCRT::free(p);
}
// end debug output
#endif

View File

@ -446,7 +446,7 @@ NS_IMETHODIMP nsHTMLEditor::SetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result=NS_ERROR_NOT_INITIALIZED;
@ -563,7 +563,7 @@ NS_IMETHODIMP nsHTMLEditor::SetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::SetTextProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -582,7 +582,7 @@ NS_IMETHODIMP nsHTMLEditor::GetInlineProperty(nsIAtom *aProperty,
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("nsTextEditor::GetTextProperty %s\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
*/
nsresult result;
@ -700,7 +700,7 @@ NS_IMETHODIMP nsHTMLEditor::RemoveInlineProperty(nsIAtom *aProperty, const nsStr
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- start nsTextEditor::RemoveInlineProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
nsresult result;
@ -806,7 +806,7 @@ NS_IMETHODIMP nsHTMLEditor::RemoveInlineProperty(nsIAtom *aProperty, const nsStr
aProperty->ToString(propString);
char *propCString = propString.ToNewCString();
if (gNoisy) { printf("---------- end nsTextEditor::RemoveInlineProperty %s ----------\n", propCString); }
delete [] propCString;
nsCRT::free(propCString);
}
return result;
}
@ -1390,7 +1390,7 @@ nsHTMLEditor::AddBlockParent(nsString& aParentTag)
{
char *tag = aParentTag.ToNewCString();
printf("---------- nsHTMLEditor::AddBlockParent %s ----------\n", tag);
delete [] tag;
nsCRT::free(tag);
}
nsresult res=NS_ERROR_NOT_INITIALIZED;
@ -1435,7 +1435,7 @@ nsHTMLEditor::ReplaceBlockParent(nsString& aParentTag)
{
char *tag = aParentTag.ToNewCString();
printf("---------- nsHTMLEditor::ReplaceBlockParent %s ----------\n", tag);
delete [] tag;
nsCRT::free(tag);
}
nsresult res=NS_ERROR_NOT_INITIALIZED;
@ -2608,7 +2608,7 @@ NS_IMETHODIMP nsHTMLEditor::SetBodyWrapWidth(PRInt32 aWrapColumn)
#ifdef DEBUG_akkana
char* curstyle = styleValue.ToNewCString();
printf("Setting style: [%s]\n", curstyle);
delete[] curstyle;
nsCRT::free(curstyle);
#endif /* DEBUG_akkana */
return bodyElement->SetAttribute(styleName, styleValue);
@ -2932,7 +2932,7 @@ NS_IMETHODIMP nsHTMLEditor::Paste()
#ifdef DEBUG_akkana
char* flav = flavor.ToNewCString();
printf("Got flavor [%s]\n", flav);
delete[] flav;
nsCRT::free(flav);
#endif
if (flavor.Equals(kHTMLMime))
{
@ -2965,7 +2965,7 @@ NS_IMETHODIMP nsHTMLEditor::Paste()
rv = NS_ERROR_NOT_IMPLEMENTED; // for now give error code
}
}
delete [] bestFlavor;
nsCRT::free(bestFlavor);
}
}
}
@ -2990,19 +2990,19 @@ NS_IMETHODIMP nsHTMLEditor::OutputToString(nsString& aOutputString,
else
{ // default processing
nsCOMPtr<nsIDocumentEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);
@ -3058,20 +3058,20 @@ NS_IMETHODIMP nsHTMLEditor::OutputToStream(nsIOutputStream* aOutputStream,
{
nsresult rv;
nsCOMPtr<nsIDocumentEncoder> encoder;
char* progid = new char[strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1];
char* progid = (char *)nsAllocator::Alloc(strlen(NS_DOC_ENCODER_PROGID_BASE) + aFormatType.Length() + 1);
if (! progid)
return NS_ERROR_OUT_OF_MEMORY;
strcpy(progid, NS_DOC_ENCODER_PROGID_BASE);
char* type = aFormatType.ToNewCString();
strcat(progid, type);
delete[] type;
nsCRT::free(type);
rv = nsComponentManager::CreateInstance(progid,
nsnull,
nsIDocumentEncoder::GetIID(),
getter_AddRefs(encoder));
delete[] progid;
nsCRT::free(progid);
if (NS_FAILED(rv))
{
printf("Couldn't get progid %s\n", progid);
@ -3594,7 +3594,7 @@ nsHTMLEditor::ReParentContentOfNode(nsIDOMNode *aNode,
{
char *tag = aParentTag.ToNewCString();
printf("---------- ReParentContentOfNode(%p,%s,%d) -----------\n", aNode, tag, aTransformation);
delete [] tag;
nsCRT::free(tag);
}
// find the current block parent, or just use aNode if it is a block node
nsCOMPtr<nsIDOMElement>blockParentElement;

View File

@ -377,7 +377,7 @@ nsTextEditorKeyListener::ProcessShortCutKeys(nsIDOMEvent* aKeyEvent, PRBool& aPr
if (buf)
{
puts(buf);
delete[] buf;
nsCRT::free(buf);
}
}
}
@ -781,7 +781,7 @@ nsTextEditorKeyListener::ProcessShortCutKeys(nsIDOMEvent* aKeyEvent, PRBool& aPr
nsString *tag = styles.StringAt(i);
char *tagCString = tag->ToNewCString();
printf("%s ", tagCString);
delete [] tagCString;
nsCRT::free(tagCString);
}
printf("\n");
}
@ -1418,7 +1418,7 @@ nsTextEditorDragListener::DragDrop(nsIDOMEvent* aMouseEvent)
dragSession->SetCanDrop(PR_TRUE);
}
delete [] whichFlavor;
nsCRT::free(whichFlavor);
// XXX This is where image support might go
//void * data;
//trans->GetTransferData(mImageDataFlavor, (void **)&data, &len);

View File

@ -629,7 +629,7 @@ nsTextEditRules::WillDeleteSelection(nsIDOMSelection *aSelection,
#ifdef DEBUG_buster
char *password = mPasswordText.ToNewCString();
printf("mPasswordText is %s\n", password);
delete [] password;
nsCRT::free(password);
#endif
}
return NS_OK;
@ -989,7 +989,7 @@ nsTextEditRules::EchoInsertionToPWBuff(nsIDOMSelection *aSelection, nsString *aO
#ifdef DEBUG_jfrancis
char *password = mPasswordText.ToNewCString();
printf("mPasswordText is %s\n", password);
delete [] password;
nsCRT::free(password);
#endif
// change the output to '*' only