mirror of
https://github.com/ading2210/libcurl.js.git
synced 2025-05-13 14:30:02 -04:00
fix possible double free when requests get aborted
This commit is contained in:
parent
11795d2772
commit
31e4e25f82
7 changed files with 41 additions and 8 deletions
|
@ -166,6 +166,8 @@ class CurlSession {
|
|||
}
|
||||
catch (e) {
|
||||
//the readable stream has been closed elsewhere, so cancel the request
|
||||
if (aborted) return;
|
||||
aborted = true;
|
||||
if (e instanceof TypeError) {
|
||||
end_callback(-1);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue