converted GetBuffer calls to ToNewCString for prunichar reasons

This commit is contained in:
valeski@netscape.com
1999-07-07 14:38:39 +00:00
parent afe14470b1
commit cf4b948f0d
4 changed files with 12 additions and 4 deletions

View File

@@ -217,8 +217,10 @@ extern "C" NS_EXPORT int DebugRobot(
if (NS_FAILED(rv)) return rv;
nsIURI *uri = nsnull;
const char *uriStr = urlName->GetBuffer();
char *uriStr = urlName->ToNewCString();
if (!uriStr) return NS_ERROR_OUT_OF_MEMORY;
rv = service->NewURI(uriStr, nsnull, &uri);
nsCRT::free(uriStr);
if (NS_FAILED(rv)) return rv;
rv = uri->QueryInterface(nsIURI::GetIID(), (void**)&url);