mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-14 10:43:24 +00:00
NECKO only: fixing MakeAbsolute when loading images, cleanup
This commit is contained in:
parent
4cb2c169f8
commit
029524c65d
@ -1225,7 +1225,7 @@ nsGenericElement::TriggerLink(nsIPresContext& aPresContext,
|
||||
if (NS_FAILED(rv)) return;
|
||||
|
||||
char *absUrl = nsnull;
|
||||
const char *uriStr = aURLSpec.ToNewCString();
|
||||
char *uriStr = aURLSpec.ToNewCString();
|
||||
|
||||
rv = service->MakeAbsolute(uriStr, baseUri, &absUrl);
|
||||
nsCRT::free(uriStr);
|
||||
|
@ -1225,7 +1225,7 @@ nsGenericElement::TriggerLink(nsIPresContext& aPresContext,
|
||||
if (NS_FAILED(rv)) return;
|
||||
|
||||
char *absUrl = nsnull;
|
||||
const char *uriStr = aURLSpec.ToNewCString();
|
||||
char *uriStr = aURLSpec.ToNewCString();
|
||||
|
||||
rv = service->MakeAbsolute(uriStr, baseUri, &absUrl);
|
||||
nsCRT::free(uriStr);
|
||||
|
@ -93,9 +93,10 @@ nsHTMLImageLoader::SetURL(const nsString& aNewSpec)
|
||||
if (NS_FAILED(rv)) return;
|
||||
|
||||
char *absUrl = nsnull;
|
||||
const char *urlSpec = mURLSpec.GetBuffer();
|
||||
char *urlSpec = mURLSpec.ToNewCString();
|
||||
rv = service->MakeAbsolute(urlSpec, baseUri, &absUrl);
|
||||
NS_RELEASE(baseUri);
|
||||
nsCRT::free(urlSpec);
|
||||
mURL = absUrl;
|
||||
delete [] absUrl;
|
||||
#endif // NECKO
|
||||
|
Loading…
Reference in New Issue
Block a user