[nodejs] Re: TLS - EPIPE error without close event being emitted

2012-07-07 Thread Thierry
Hey Gary, I am also working on a node.js library for Apple Push Notifications: https://github.com/Orion98MC/node_apns I do check if the stream is writable before sending anything. You can checkout my code on github: https://github.com/Orion98MC/node_apns/blob/master/lib/apns.js:230 Also, I'd

Re: [nodejs] Re: TLS - EPIPE error without close event being emitted

2012-06-09 Thread Garry Watkins
It is defined above in a var statement. Sent from my iPhone On Jun 9, 2012, at 11:52 AM, Ben Noordhuis wrote: > On Sat, Jun 9, 2012 at 6:47 AM, catshow wrote: >> This is what I use to connect via TLS. According to the >> documentation "tls.connect() returns a CleartextStream object." >> >>

Re: [nodejs] Re: TLS - EPIPE error without close event being emitted

2012-06-09 Thread Ben Noordhuis
On Sat, Jun 9, 2012 at 6:47 AM, catshow wrote: > This is what I use to connect via TLS.   According to the > documentation "tls.connect() returns a CleartextStream object." > >    const tlsOptions = { >        "cert":fs.readFileSync(config.certFile), >        "key":fs.readFileSync(config.keyFile),

[nodejs] Re: TLS - EPIPE error without close event being emitted

2012-06-08 Thread catshow
This is what I use to connect via TLS. According to the documentation "tls.connect() returns a CleartextStream object." const tlsOptions = { "cert":fs.readFileSync(config.certFile), "key":fs.readFileSync(config.keyFile), "passphrase":config.passphrase }; cons