Skip to content
This repository was archived by the owner on Sep 16, 2024. It is now read-only.

Commit ed0ac50

Browse files
author
iwahdan88
committed
esp32/modusocket: Releasing GIL when performing ssl/tls handshake
1 parent efa74cb commit ed0ac50

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

esp32/mods/modusocket.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -542,9 +542,11 @@ STATIC mp_obj_t socket_do_handshake(mp_obj_t self_in) {
542542
mod_network_socket_obj_t *self = self_in;
543543

544544
int _errno;
545+
MP_THREAD_GIL_EXIT();
545546
if (self->sock_base.nic_type->n_setupssl(self, &_errno) != 0) {
546547
nlr_raise(mp_obj_new_exception_arg1(&mp_type_OSError, MP_OBJ_NEW_SMALL_INT(_errno)));
547548
}
549+
MP_THREAD_GIL_ENTER();
548550
return mp_const_none;
549551
}
550552
STATIC MP_DEFINE_CONST_FUN_OBJ_1(socket_do_handshake_obj, socket_do_handshake);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy