tong / hxssl

Haxe→C++/Neko OpenSSL bindings
30 stars 45 forks source link

SSL_recv_char does not handle eof #9

Closed hexonaut closed 11 years ago

hexonaut commented 11 years ago

SSL_recv_char will return garbage if the socket has been closed. This can potentially cause infinite loops in SocketInput when something like readLine() is called. The fix is simple and just requires returning a neko error when the result of SSL_read is less than or equal to 0.

hexonaut commented 11 years ago

This has been solved in my pull request so you can close it now.