@@ -110,7 +110,7 @@ struct COVER_tryParameters_data_t<'a, 'b> {
110110 dictBufferCapacity : size_t ,
111111 parameters : ZDICT_cover_params_t ,
112112}
113- #[ derive( Copy , Clone ) ]
113+ #[ derive( Clone ) ]
114114#[ repr( C ) ]
115115pub ( super ) struct COVER_dictSelection_t {
116116 dictContent : * mut u8 ,
@@ -977,7 +977,7 @@ pub(super) fn COVER_best_start(best: &mut COVER_best_t) {
977977pub ( super ) unsafe fn COVER_best_finish (
978978 best : & mut COVER_best_t ,
979979 parameters : ZDICT_cover_params_t ,
980- selection : COVER_dictSelection_t ,
980+ selection : & COVER_dictSelection_t ,
981981) {
982982 let dict = selection. dictContent as * mut core:: ffi:: c_void ;
983983 let compressedSize = selection. totalCompressedSize ;
@@ -1019,8 +1019,8 @@ pub(super) fn COVER_dictSelectionError(error: size_t) -> COVER_dictSelection_t {
10191019 setDictSelection ( core:: ptr:: null_mut ( ) , 0 , error)
10201020}
10211021
1022- pub ( super ) fn COVER_dictSelectionIsError ( selection : COVER_dictSelection_t ) -> core:: ffi:: c_uint {
1023- ( ERR_isError ( selection. totalCompressedSize ) || ( selection. dictContent ) . is_null ( ) )
1022+ pub ( super ) fn COVER_dictSelectionIsError ( selection : & COVER_dictSelection_t ) -> core:: ffi:: c_uint {
1023+ ( ERR_isError ( selection. totalCompressedSize ) || selection. dictContent . is_null ( ) )
10241024 as core:: ffi:: c_int as core:: ffi:: c_uint
10251025}
10261026
@@ -1179,11 +1179,11 @@ unsafe fn COVER_tryParameters(opaque: *mut core::ffi::c_void) {
11791179 totalCompressedSize,
11801180 ) ;
11811181
1182- if COVER_dictSelectionIsError ( selection) != 0 && displayLevel >= 1 {
1182+ if COVER_dictSelectionIsError ( & selection) != 0 && displayLevel >= 1 {
11831183 eprintln ! ( "Failed to select dictionary" ) ;
11841184 }
11851185 drop ( dict) ;
1186- COVER_best_finish ( ( * data) . best , parameters, selection) ;
1186+ COVER_best_finish ( ( * data) . best , parameters, & selection) ;
11871187 free ( data as * mut core:: ffi:: c_void ) ;
11881188 COVER_map_destroy ( & mut activeDmers) ;
11891189 COVER_dictSelectionFree ( selection) ;
0 commit comments