Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 86a5690

Browse filesBrowse files
Diana HollandMylesBorins
authored andcommitted
crypto: move field initialization to class
PR-URL: #23610 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com> Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
1 parent 6af2f9f commit 86a5690
Copy full SHA for 86a5690

File tree

Expand file treeCollapse file tree

2 files changed

+11
-18
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

2 files changed

+11
-18
lines changed
Open diff view settings
Collapse file

‎src/node_crypto_clienthello-inl.h‎

Copy file name to clipboardExpand all lines: src/node_crypto_clienthello-inl.h
+1-8Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,7 @@ inline ClientHelloParser::ClientHelloParser()
3434
: state_(kEnded),
3535
onhello_cb_(nullptr),
3636
onend_cb_(nullptr),
37-
cb_arg_(nullptr),
38-
session_size_(0),
39-
session_id_(nullptr),
40-
servername_size_(0),
41-
servername_(nullptr),
42-
ocsp_request_(0),
43-
tls_ticket_size_(0),
44-
tls_ticket_(nullptr) {
37+
cb_arg_(nullptr) {
4538
Reset();
4639
}
4740

Collapse file

‎src/node_crypto_clienthello.h‎

Copy file name to clipboardExpand all lines: src/node_crypto_clienthello.h
+10-10Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -108,16 +108,16 @@ class ClientHelloParser {
108108
OnHelloCb onhello_cb_;
109109
OnEndCb onend_cb_;
110110
void* cb_arg_;
111-
size_t frame_len_;
112-
size_t body_offset_;
113-
size_t extension_offset_;
114-
uint8_t session_size_;
115-
const uint8_t* session_id_;
116-
uint16_t servername_size_;
117-
const uint8_t* servername_;
118-
uint8_t ocsp_request_;
119-
uint16_t tls_ticket_size_;
120-
const uint8_t* tls_ticket_;
111+
size_t frame_len_ = 0;
112+
size_t body_offset_ = 0;
113+
size_t extension_offset_ = 0;
114+
uint8_t session_size_ = 0;
115+
const uint8_t* session_id_ = nullptr;
116+
uint16_t servername_size_ = 0;
117+
const uint8_t* servername_ = nullptr;
118+
uint8_t ocsp_request_ = 0;
119+
uint16_t tls_ticket_size_ = -1;
120+
const uint8_t* tls_ticket_ = nullptr;
121121
};
122122

123123
} // namespace crypto

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.