mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-12-23 20:46:50 +03:00
Ensure we propagate the error to our client, and then abort the llcache handle, should we fail to find a content when converting a nascent hlcache context into an object
svn path=/trunk/netsurf/; revision=10453
This commit is contained in:
parent
3d31372b9d
commit
7eef1a387a
@ -356,7 +356,17 @@ nserror hlcache_llcache_callback(llcache_handle *handle,
|
|||||||
ctx->accepted_types, &type)) {
|
ctx->accepted_types, &type)) {
|
||||||
error = hlcache_find_content(ctx);
|
error = hlcache_find_content(ctx);
|
||||||
if (error != NSERROR_OK) {
|
if (error != NSERROR_OK) {
|
||||||
free((char *) ctx->child.charset);
|
hlcache_event hlevent;
|
||||||
|
|
||||||
|
hlevent.type = CONTENT_MSG_ERROR;
|
||||||
|
hlevent.data.error = messages_get("MiscError");
|
||||||
|
|
||||||
|
ctx->handle->cb(ctx->handle, &hlevent,
|
||||||
|
ctx->handle->pw);
|
||||||
|
|
||||||
|
llcache_handle_abort(handle);
|
||||||
|
llcache_handle_release(handle);
|
||||||
|
free((char *) ctx->child.charset);
|
||||||
free(ctx);
|
free(ctx);
|
||||||
return error;
|
return error;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user