@@ -26,7 +26,7 @@ cfg_if::cfg_if! {
2626pub ( crate ) use _ssl:: module_def;
2727
2828use openssl_probe:: ProbeResult ;
29- use std :: sync :: LazyLock ;
29+ use rustpython_common :: lock :: LazyLock ;
3030
3131// define our own copy of ProbeResult so we can handle the vendor case
3232// easily, without having to have a bunch of cfgs
@@ -95,7 +95,6 @@ mod _ssl {
9595 fmt,
9696 io:: { Read , Write } ,
9797 path:: { Path , PathBuf } ,
98- sync:: LazyLock ,
9998 time:: Instant ,
10099 } ;
101100
@@ -106,7 +105,7 @@ mod _ssl {
106105 // if openssl is vendored, it doesn't know the locations
107106 // of system certificates - cache the probe result now.
108107 #[ cfg( openssl_vendored) ]
109- std :: sync :: LazyLock :: force ( & super :: PROBE ) ;
108+ rustpython_common :: lock :: LazyLock :: force ( & super :: PROBE ) ;
110109
111110 __module_exec ( vm, module) ;
112111 Ok ( ( ) )
@@ -569,7 +568,7 @@ mod _ssl {
569568
570569 // Get or create an ex_data index for SNI callback data
571570 fn get_sni_ex_data_index ( ) -> libc:: c_int {
572- use std :: sync :: LazyLock ;
571+ use rustpython_common :: lock :: LazyLock ;
573572 static SNI_EX_DATA_IDX : LazyLock < libc:: c_int > = LazyLock :: new ( || unsafe {
574573 sys:: SSL_get_ex_new_index (
575574 0 ,
@@ -613,7 +612,7 @@ mod _ssl {
613612
614613 // Get or create an ex_data index for msg_callback data
615614 fn get_msg_callback_ex_data_index ( ) -> libc:: c_int {
616- use std :: sync :: LazyLock ;
615+ use rustpython_common :: lock :: LazyLock ;
617616 static MSG_CB_EX_DATA_IDX : LazyLock < libc:: c_int > = LazyLock :: new ( || unsafe {
618617 sys:: SSL_get_ex_new_index (
619618 0 ,
0 commit comments