electron/shell/browser/net
trop[bot] 292dd765b2
fix: always terminate active Node Streams (#43070)
`.destroy()` is an important method in the lifecycle of a Node.js
Readable stream. It is typically called to reclaim the resources
(e.g., close file descriptor). The only situations where calling
it manually isn't necessary are when the following events are
emitted first:

- `end`: natural end of a stream
- `error`: stream terminated due to a failure

Prior to this commit the ended state was incorrectly tracked together
with a pending internal error. It led to situations where the request
could get aborted during a read and then get marked as ended (having
pending error).

With this change we disentangle pending "error" and "destroyed" cases to
always properly terminate an active Node.js Readable stream.

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Fedor Indutny <79877362+indutny-signal@users.noreply.github.com>
2024-07-27 14:00:44 -05:00
..
asar chore: bump chromium to 128.0.6611.0 (32-x-y) (#43017) 2024-07-25 11:24:11 +02:00
cert_verifier_client.cc chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
cert_verifier_client.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
electron_url_loader_factory.cc chore: migrate base::StringPiece to std::string_view (#40915) 2024-01-10 19:00:37 -06:00
electron_url_loader_factory.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
network_context_service.cc refactor: inline simple getters (#41125) 2024-01-29 20:43:28 -06:00
network_context_service.h chore: enable check raw ptr fields (#38167) 2023-05-11 16:07:39 -04:00
network_context_service_factory.cc refactor: prefer using base::NoDestructor to base::{Singleton,LazyInstance} (#41400) 2024-02-23 10:35:20 +01:00
network_context_service_factory.h refactor: prefer using base::NoDestructor to base::{Singleton,LazyInstance} (#41400) 2024-02-23 10:35:20 +01:00
node_stream_loader.cc fix: always terminate active Node Streams (#43070) 2024-07-27 14:00:44 -05:00
node_stream_loader.h fix: always terminate active Node Streams (#43070) 2024-07-27 14:00:44 -05:00
proxying_url_loader_factory.cc chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
proxying_url_loader_factory.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
proxying_websocket.cc chore: bump chromium to 127.0.6521.0 (main) (#42118) 2024-06-07 17:18:35 -04:00
proxying_websocket.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
resolve_host_function.cc chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
resolve_host_function.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
resolve_proxy_helper.cc fix: crash when resolving proxy due to network service restart (#42898) 2024-07-15 14:50:38 +02:00
resolve_proxy_helper.h fix: crash when resolving proxy due to network service restart (#42898) 2024-07-15 14:50:38 +02:00
system_network_context_manager.cc chore: bump chromium to 127.0.6521.0 (main) (#42118) 2024-06-07 17:18:35 -04:00
system_network_context_manager.h chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
url_pipe_loader.cc chore: replace absl::optional<T> with std::optional<T> (#40928) 2024-01-10 16:23:35 -06:00
url_pipe_loader.h chore: bump chromium to 128.0.6611.0 (32-x-y) (#43017) 2024-07-25 11:24:11 +02:00
web_request_api_interface.h chore: add ELECTRON_ prefix to C++ include guards (#31925) 2021-11-22 16:34:31 +09:00