Do not abort fetch on receipt of FETCH_ERROR: the fetch has already been destroyed.
Implement LLCACHE_EVENT_ERROR case of hlcache_llcache_callback(). svn path=/trunk/netsurf/; revision=10218
This commit is contained in:
parent
57e7a172e1
commit
9f575c590b
|
@ -175,7 +175,14 @@ nserror hlcache_llcache_callback(llcache_handle *handle,
|
|||
/* should never happen: the handler must be changed */
|
||||
break;
|
||||
case LLCACHE_EVENT_ERROR:
|
||||
/** \todo handle errors */
|
||||
if (ctx->handle->cb != NULL) {
|
||||
hlcache_event hlevent;
|
||||
|
||||
hlevent.type = CONTENT_MSG_ERROR;
|
||||
hlevent.data.error = event->data.msg;
|
||||
|
||||
ctx->handle->cb(ctx->handle, &hlevent, ctx->handle->pw);
|
||||
}
|
||||
break;
|
||||
case LLCACHE_EVENT_PROGRESS:
|
||||
break;
|
||||
|
|
|
@ -1327,7 +1327,7 @@ void llcache_fetch_callback(fetch_msg msg, void *p, const void *data,
|
|||
/* Out-of-band information */
|
||||
case FETCH_ERROR:
|
||||
/* An error occurred while fetching */
|
||||
fetch_abort(object->fetch.fetch);
|
||||
/* The fetch has has already been cleaned up by the fetcher */
|
||||
object->fetch.fetch = NULL;
|
||||
/** \todo Ensure this object becomes stale */
|
||||
|
||||
|
|
Loading…
Reference in New Issue