File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -895,9 +895,9 @@ impl WriteOptionsBuilder {
895895 match self . encryption {
896896 Encryption :: Aes => CipherAlgorithm :: Aes ,
897897 Encryption :: Camellia => CipherAlgorithm :: Camellia ,
898- _ => panic ! (
899- "unsupported encryption method for writing: {:? }" ,
900- self . encryption
898+ other => panic ! (
899+ "unsupported encryption method for writing: byte={ }" ,
900+ other . to_byte ( )
901901 ) ,
902902 } ,
903903 self . cipher_mode ,
@@ -911,9 +911,9 @@ impl WriteOptionsBuilder {
911911 Compression :: Deflate => Compress :: Deflate ( self . compression_level . into ( ) ) ,
912912 Compression :: ZStandard => Compress :: ZStandard ( self . compression_level . into ( ) ) ,
913913 Compression :: XZ => Compress :: XZ ( self . compression_level . into ( ) ) ,
914- _ => panic ! (
915- "unsupported compression method for writing: {:? }" ,
916- self . compression
914+ other => panic ! (
915+ "unsupported compression method for writing: byte={ }" ,
916+ other . to_byte ( )
917917 ) ,
918918 } ,
919919 cipher,
Original file line number Diff line number Diff line change @@ -62,7 +62,7 @@ pub(crate) fn decrypt_reader<R: Read>(
6262 return Err ( io:: Error :: new (
6363 io:: ErrorKind :: Unsupported ,
6464 format ! ( "unsupported encryption method: {encryption:?}" ) ,
65- ) )
65+ ) ) ;
6666 }
6767 } )
6868}
@@ -86,7 +86,7 @@ pub(crate) fn decompress_reader<R: Read>(
8686 return Err ( io:: Error :: new (
8787 io:: ErrorKind :: Unsupported ,
8888 format ! ( "unsupported compression method: {compression:?}" ) ,
89- ) )
89+ ) ) ;
9090 }
9191 } )
9292}
Original file line number Diff line number Diff line change @@ -165,7 +165,7 @@ fn encryption_writer<W: Write>(
165165 return Err ( io:: Error :: new (
166166 io:: ErrorKind :: Unsupported ,
167167 format ! ( "unsupported cipher mode for writing: {:?}" , context. mode) ,
168- ) )
168+ ) ) ;
169169 }
170170 } )
171171}
You can’t perform that action at this time.
0 commit comments