mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-22 02:09:28 +00:00
Fixed GetPort
This commit is contained in:
parent
75e68a0c2e
commit
165315ccac
@ -69,7 +69,7 @@ nsFileChannel::Init(nsFileProtocolHandler* handler,
|
||||
|
||||
if (getter) {
|
||||
rv = getter->GetEventSink(verb, nsIStreamListener::GetIID(), (nsISupports**)&mListener);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
// ignore the failure -- we can live without having an event sink
|
||||
}
|
||||
|
||||
mURI = uri;
|
||||
|
@ -92,7 +92,7 @@ nsFileProtocolHandler::GetScheme(char* *result)
|
||||
NS_IMETHODIMP
|
||||
nsFileProtocolHandler::GetDefaultPort(PRInt32 *result)
|
||||
{
|
||||
*result = 21;
|
||||
*result = -1; // no port for file: URLs
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user