File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -619,7 +619,7 @@ impl IndexEntry {
619619 ///
620620 /// The returned `raw::git_index_entry` contains a pointer to a `CString` path, which is also
621621 /// returned because it's lifetime must exceed the lifetime of the `raw::git_index_entry`.
622- pub fn to_raw ( & self ) -> Result < ( raw:: git_index_entry , CString ) , Error > {
622+ pub ( crate ) unsafe fn to_raw ( & self ) -> Result < ( raw:: git_index_entry , CString ) , Error > {
623623 let path = CString :: new ( & self . path [ ..] ) ?;
624624
625625 // libgit2 encodes the length of the path in the lower bits of the
Original file line number Diff line number Diff line change @@ -2516,11 +2516,11 @@ impl Repository {
25162516 theirs : & IndexEntry ,
25172517 opts : Option < & mut MergeFileOptions > ,
25182518 ) -> Result < MergeFileResult < ' _ > , Error > {
2519- let ( ancestor, _ancestor_path) = ancestor. to_raw ( ) ?;
2520- let ( ours, _ours_path) = ours. to_raw ( ) ?;
2521- let ( theirs, _theirs_path) = theirs. to_raw ( ) ?;
2522-
25232519 unsafe {
2520+ let ( ancestor, _ancestor_path) = ancestor. to_raw ( ) ?;
2521+ let ( ours, _ours_path) = ours. to_raw ( ) ?;
2522+ let ( theirs, _theirs_path) = theirs. to_raw ( ) ?;
2523+
25242524 let mut ret = mem:: zeroed ( ) ;
25252525 try_call ! ( raw:: git_merge_file_from_index(
25262526 & mut ret,
You can’t perform that action at this time.
0 commit comments