Avoid a warning by explicitly calling drop.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
(cherry picked from commit 4f7d15508f
)
This commit is contained in:
parent
fe7b87a96c
commit
cfa4590c75
|
@ -63,7 +63,7 @@ pub extern "C" fn zip339_free_phrase(phrase: *const c_char) {
|
|||
if !phrase.is_null() {
|
||||
unsafe {
|
||||
// It is correct to cast away const here; the memory is not actually immutable.
|
||||
CString::from_raw(phrase as *mut c_char);
|
||||
drop(CString::from_raw(phrase as *mut c_char));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue