TODO: Remove or refactor this.
(ptr: *const c_char)
| 26 | |
| 27 | // TODO: Remove or refactor this. |
| 28 | pub(crate) fn raw_to_string(ptr: *const c_char) -> Option<String> { |
| 29 | if ptr.is_null() { |
| 30 | None |
| 31 | } else { |
| 32 | Some(unsafe { CStr::from_ptr(ptr).to_string_lossy().into_owned() }) |
| 33 | } |
| 34 | } |
| 35 | |
| 36 | // TODO: Make this pass in an iterator over something more generic... |
| 37 | pub(crate) fn strings_to_string_list(strings: &[String]) -> *mut *mut c_char { |
no outgoing calls
no test coverage detected