Bug 350511: treat request timeouts as backoff errors

patch: treat NS_ERROR_NET_TIMEOUT as an error
r=darin
This commit is contained in:
tony%ponderer.org 2006-09-06 17:04:36 +00:00
Родитель 137db787c9
Коммит bbced43af2
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -101,7 +101,8 @@ TableUpdateListener::OnStartRequest(nsIRequest *request, nsISupports* context)
nsresult status;
rv = httpChannel->GetStatus(&status);
NS_ENSURE_SUCCESS(rv, rv);
if (NS_ERROR_CONNECTION_REFUSED == status) {
if (NS_ERROR_CONNECTION_REFUSED == status ||
NS_ERROR_NET_TIMEOUT == status) {
// Assume that we're overloading the server and trigger backoff.
mErrorCallback->HandleEvent(nsCString());
return NS_ERROR_ABORT;