MCPcopy Index your code
hub / github.com/RustPython/RustPython / minimum_version

Method minimum_version

crates/stdlib/src/openssl.rs:1240–1248  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

1238 // PY_PROTO_MINIMUM_SUPPORTED = -2, PY_PROTO_MAXIMUM_SUPPORTED = -1
1239 #[pygetset]
1240 fn minimum_version(&self) -> i32 {
1241 let ctx = self.ctx();
1242 let version = unsafe { sys::SSL_CTX_get_min_proto_version(ctx.as_ptr()) };
1243 if version == 0 {
1244 -2 // PY_PROTO_MINIMUM_SUPPORTED
1245 } else {
1246 version
1247 }
1248 }
1249 #[pygetset(setter)]
1250 fn set_minimum_version(&self, value: i32, vm: &VirtualMachine) -> PyResult<()> {
1251 // Handle special values

Callers

nothing calls this directly

Calls 2

ctxMethod · 0.45
as_ptrMethod · 0.45

Tested by

no test coverage detected