No implicit conversions from long to int

source/sslsocket.d(44): Error: function deimos.openssl.ssl.SSL_read
(ssl_st* ssl, void* buf, int num) is not callable using argument types
(ssl_st*, void*, ulong)
This commit is contained in:
Chloride Cull 2014-08-24 16:49:49 +02:00
parent 2e5245d016
commit 7ecd24393f
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ class OpenSslSocket : Socket {
} }
@trusted @trusted
override ptrdiff_t receive(void[] buf, SocketFlags flags) { override ptrdiff_t receive(void[] buf, SocketFlags flags) {
return SSL_read(ssl, buf.ptr, buf.length); return SSL_read(ssl, buf.ptr, cast(int)buf.length);
} }
override ptrdiff_t receive(void[] buf) { override ptrdiff_t receive(void[] buf) {
return receive(buf, SocketFlags.NONE); return receive(buf, SocketFlags.NONE);