@@ -749,8 +749,8 @@ _zstd.ZstdCompressor.set_pledged_input_size
749749Set the uncompressed content size to be written into the frame header.
750750
751751This method can be used to ensure the header of the frame about to be written
752- includes the size of the data, unless CompressionParameter.content_size_flag is
753- set to False. If last_mode != FLUSH_FRAME, then a RuntimeError is raised.
752+ includes the size of the data, unless the CompressionParameter.content_size_flag
753+ is set to False. If last_mode != FLUSH_FRAME, then a RuntimeError is raised.
754754
755755It is important to ensure that the pledged data size matches the actual data
756756size. If they do not match the compressed output data may be corrupted and the
@@ -762,8 +762,6 @@ _zstd_ZstdCompressor_set_pledged_input_size_impl(ZstdCompressor *self,
762762 unsigned long long size )
763763/*[clinic end generated code: output=3a09e55cc0e3b4f9 input=563b9a1ddd4facc3]*/
764764{
765- size_t zstd_ret ;
766-
767765 // Error occured while converting argument, should be unreachable
768766 assert (size != ZSTD_CONTENTSIZE_ERROR );
769767
@@ -780,7 +778,7 @@ _zstd_ZstdCompressor_set_pledged_input_size_impl(ZstdCompressor *self,
780778 }
781779
782780 /* Set pledged content size */
783- zstd_ret = ZSTD_CCtx_setPledgedSrcSize (self -> cctx , size );
781+ size_t zstd_ret = ZSTD_CCtx_setPledgedSrcSize (self -> cctx , size );
784782 PyMutex_Unlock (& self -> lock );
785783 if (ZSTD_isError (zstd_ret )) {
786784 _zstd_state * mod_state = PyType_GetModuleState (Py_TYPE (self ));
0 commit comments