File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -2020,7 +2020,8 @@ fn WriteMetaBlockInternal<Alloc: BrotliAlloc,
20202020 false ,
20212021 cb) ;
20222022 if actual_is_last != is_last {
2023- if params. byte_align {
2023+ // insert empty block for byte alignment if required
2024+ if params. byte_align && ( ( * storage_ix & 7u32 as ( usize ) ) != 0 ) {
20242025 BrotliStoreSyncMetaBlock ( storage_ix, storage) ;
20252026 }
20262027 BrotliWriteEmptyLastMetaBlock ( storage_ix, storage)
@@ -2163,7 +2164,8 @@ fn WriteMetaBlockInternal<Alloc: BrotliAlloc,
21632164 cb) ;
21642165 }
21652166 if actual_is_last != is_last {
2166- if params. byte_align {
2167+ // insert empty block for byte alignment if required
2168+ if params. byte_align && ( ( * storage_ix & 7u32 as ( usize ) ) != 0 ) {
21672169 BrotliStoreSyncMetaBlock ( storage_ix, storage) ;
21682170 }
21692171 BrotliWriteEmptyLastMetaBlock ( storage_ix, storage)
You can’t perform that action at this time.
0 commit comments