diff options
author | Paul Kehrer <paul.l.kehrer@gmail.com> | 2016-09-20 20:10:25 -0500 |
---|---|---|
committer | Alex Gaynor <alex.gaynor@gmail.com> | 2016-09-20 21:10:25 -0400 |
commit | 9f9113a7bb736a835f978d27e95603c8d6f52b7c (patch) | |
tree | b91f8e803968018557711cf2e4d9ee64910ea7b0 /src/OpenSSL/SSL.py | |
parent | 6b68c0e6ce6c19c6985505f0dd1340d44bda1b04 (diff) | |
download | pyopenssl-9f9113a7bb736a835f978d27e95603c8d6f52b7c.tar.gz |
fix cffi warnings for proper buffer types (#545)
Diffstat (limited to 'src/OpenSSL/SSL.py')
-rw-r--r-- | src/OpenSSL/SSL.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/OpenSSL/SSL.py b/src/OpenSSL/SSL.py index 3f97ccb..2d76516 100644 --- a/src/OpenSSL/SSL.py +++ b/src/OpenSSL/SSL.py @@ -1613,7 +1613,7 @@ class Connection(object): return None length = _lib.SSL_get_server_random(self._ssl, _ffi.NULL, 0) assert length > 0 - outp = _ffi.new("char[]", length) + outp = _ffi.new("unsigned char[]", length) _lib.SSL_get_server_random(self._ssl, outp, length) return _ffi.buffer(outp, length)[:] @@ -1629,7 +1629,7 @@ class Connection(object): length = _lib.SSL_get_client_random(self._ssl, _ffi.NULL, 0) assert length > 0 - outp = _ffi.new("char[]", length) + outp = _ffi.new("unsigned char[]", length) _lib.SSL_get_client_random(self._ssl, outp, length) return _ffi.buffer(outp, length)[:] @@ -1645,7 +1645,7 @@ class Connection(object): length = _lib.SSL_SESSION_get_master_key(session, _ffi.NULL, 0) assert length > 0 - outp = _ffi.new("char[]", length) + outp = _ffi.new("unsigned char[]", length) _lib.SSL_SESSION_get_master_key(session, outp, length) return _ffi.buffer(outp, length)[:] |