tls_wrap: move members to initialization list

They didn't need to be defined in the body of the constructor.
pull/5010/head
Trevor Norris 2013-11-05 11:56:13 -08:00
parent 5235d71f89
commit 4326c6d1b3
1 changed files with 2 additions and 5 deletions

View File

@ -65,6 +65,8 @@ TLSCallbacks::TLSCallbacks(Environment* env,
: SSLWrap<TLSCallbacks>(env, Unwrap<SecureContext>(sc), kind), : SSLWrap<TLSCallbacks>(env, Unwrap<SecureContext>(sc), kind),
StreamWrapCallbacks(old), StreamWrapCallbacks(old),
AsyncWrap(env, env->tls_wrap_constructor_function()->NewInstance()), AsyncWrap(env, env->tls_wrap_constructor_function()->NewInstance()),
sc_(Unwrap<SecureContext>(sc)),
sc_handle_(env->isolate(), sc),
enc_in_(NULL), enc_in_(NULL),
enc_out_(NULL), enc_out_(NULL),
clear_in_(NULL), clear_in_(NULL),
@ -73,11 +75,6 @@ TLSCallbacks::TLSCallbacks(Environment* env,
started_(false), started_(false),
established_(false), established_(false),
shutdown_(false) { shutdown_(false) {
// Persist SecureContext
sc_ = Unwrap<SecureContext>(sc);
sc_handle_.Reset(node_isolate, sc);
node::Wrap<TLSCallbacks>(object(), this); node::Wrap<TLSCallbacks>(object(), this);
// Initialize queue for clearIn writes // Initialize queue for clearIn writes