mirror of
https://github.com/ading2210/libcurl.js.git
synced 2025-05-13 14:30:02 -04:00
update wisp server, fix some memory issues
This commit is contained in:
parent
8ac0f40896
commit
11795d2772
8 changed files with 57 additions and 46 deletions
|
@ -55,7 +55,10 @@ class HTTPSession extends CurlSession {
|
|||
resolve(response);
|
||||
}
|
||||
let finish_callback = (error) => {
|
||||
_free(body_ptr);
|
||||
if (body_ptr != null) {
|
||||
_free(body_ptr);
|
||||
body_ptr = null;
|
||||
}
|
||||
if (error > 0) {
|
||||
error_msg(`Request "${url}" failed with error code ${error}: ${get_error_str(error)}`);
|
||||
reject(`Request failed with error code ${error}: ${get_error_str(error)}`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue