diff --git a/lib/internal/quic/core.js b/lib/internal/quic/core.js index 5074cb279606bd..f7d801acb067ee 100644 --- a/lib/internal/quic/core.js +++ b/lib/internal/quic/core.js @@ -474,14 +474,6 @@ function onSessionQlog(str) { } } -// Called when an error occurs in a QuicSession. When this happens, -// the only remedy is to destroy the session. -function onSessionError(error) { - if (this[owner_symbol]) { - this[owner_symbol].destroy(error); - } -} - // Called by the C++ internals when a client QuicSession receives // a version negotiation response from the server. function onSessionVersionNegotiation( @@ -570,7 +562,6 @@ setCallbacks({ onSessionClientHello, onSessionClose, onSessionDestroyed, - onSessionError, onSessionHandshake, onSessionKeylog, onSessionQlog, diff --git a/src/env.h b/src/env.h index 54e86db2f47e0b..f16c79b500171c 100644 --- a/src/env.h +++ b/src/env.h @@ -455,7 +455,6 @@ constexpr size_t kFsStatsBufferLength = V(quic_on_session_client_hello_function, v8::Function) \ V(quic_on_session_close_function, v8::Function) \ V(quic_on_session_destroyed_function, v8::Function) \ - V(quic_on_session_error_function, v8::Function) \ V(quic_on_session_handshake_function, v8::Function) \ V(quic_on_session_keylog_function, v8::Function) \ V(quic_on_session_path_validation_function, v8::Function) \ diff --git a/src/quic/node_quic.cc b/src/quic/node_quic.cc index 62e98782931342..a879e31d8706c3 100644 --- a/src/quic/node_quic.cc +++ b/src/quic/node_quic.cc @@ -60,7 +60,6 @@ void QuicSetCallbacks(const FunctionCallbackInfo& args) { SETFUNCTION("onSessionClientHello", session_client_hello); SETFUNCTION("onSessionClose", session_close); SETFUNCTION("onSessionDestroyed", session_destroyed); - SETFUNCTION("onSessionError", session_error); SETFUNCTION("onSessionHandshake", session_handshake); SETFUNCTION("onSessionKeylog", session_keylog); SETFUNCTION("onSessionUsePreferredAddress", session_use_preferred_address);