fix: wasi context leak htt

master
Sean McBride 3 years ago
parent 16e2613c05
commit bdfbff9adb

@ -34,8 +34,6 @@ sandbox_set_as_returned(struct sandbox *sandbox, sandbox_state_t last_state)
sandbox->total_time = now - sandbox->timestamp_of.request_arrival;
local_runqueue_delete(sandbox);
sandbox_free_linear_memory(sandbox);
http_session_free(sandbox->http);
sandbox->http = NULL;
break;
}
default: {

@ -202,14 +202,13 @@ sandbox_deinit(struct sandbox *sandbox)
module_release(sandbox->module);
/* HTTP Session was already deinited, freed, and set to NULL */
/* Linear Memory and Guard Page should already have been munmaped and set to NULL */
assert(sandbox->memory == NULL);
if (likely(sandbox->stack != NULL)) sandbox_free_stack(sandbox);
if (likely(sandbox->http != NULL)) http_session_free(sandbox->http);
if (likely(sandbox->globals.buffer != NULL)) sandbox_free_globals(sandbox);
if (likely(sandbox->wasi_context != NULL)) wasi_context_destroy(sandbox->wasi_context);
}
/**

Loading…
Cancel
Save