projects
/
platform
/
upstream
/
nodejs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bfb9d5b
)
tls: Provide buffer to Connection.setSession
author
isaacs
<i@izs.me>
Sat, 13 Oct 2012 01:41:30 +0000
(18:41 -0700)
committer
isaacs
<i@izs.me>
Tue, 23 Oct 2012 17:48:50 +0000
(10:48 -0700)
lib/tls.js
patch
|
blob
|
history
diff --git
a/lib/tls.js
b/lib/tls.js
index
ed6c5a7
..
e184c29
100644
(file)
--- a/
lib/tls.js
+++ b/
lib/tls.js
@@
-1296,7
+1296,10
@@
exports.connect = function(/* [port, host], options, cb */) {
});
if (options.session) {
- pair.ssl.setSession(options.session);
+ var session = options.session;
+ if (typeof session === 'string')
+ session = new Buffer(session, 'binary');
+ pair.ssl.setSession(session);
}
var cleartext = pipe(pair, socket);