Skip to content

Commit 760cb46

Browse files
committed
Shutdown and free SSL in unwrap
1 parent 89667f9 commit 760cb46

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

wolfssl/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,8 @@ def unwrap(self):
733733
Returns the wrapped OS socket.
734734
"""
735735
if self.native_object != _ffi.NULL:
736-
_lib.wolfSSL_set_fd(self.native_object, -1)
736+
_lib.wolfSSL_shutdown(self.native_object)
737+
self._release_native_object()
737738

738739
sock = socket(family=self._sock.family,
739740
sock_type=self._sock.type,

0 commit comments

Comments
 (0)