fix manual_c_str_literals clippy warning
This commit is contained in:
parent
af9df3765d
commit
76b592673f
|
|
@ -219,7 +219,7 @@ struct BIO_METHOD(*mut ffi::BIO_METHOD);
|
||||||
impl BIO_METHOD {
|
impl BIO_METHOD {
|
||||||
fn new<S: Read + Write>() -> BIO_METHOD {
|
fn new<S: Read + Write>() -> BIO_METHOD {
|
||||||
unsafe {
|
unsafe {
|
||||||
let ptr = ffi::BIO_meth_new(ffi::BIO_TYPE_NONE, b"rust\0".as_ptr().cast());
|
let ptr = ffi::BIO_meth_new(ffi::BIO_TYPE_NONE, c"rust".as_ptr().cast());
|
||||||
assert!(!ptr.is_null());
|
assert!(!ptr.is_null());
|
||||||
let ret = BIO_METHOD(ptr);
|
let ret = BIO_METHOD(ptr);
|
||||||
assert!(ffi::BIO_meth_set_write(ptr, Some(bwrite::<S>)) != 0);
|
assert!(ffi::BIO_meth_set_write(ptr, Some(bwrite::<S>)) != 0);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue