Skip to content

Commit d80856c

Browse files
committed
chore: add license header to fix ci
1 parent bddce62 commit d80856c

File tree

2 files changed

+19
-2
lines changed

2 files changed

+19
-2
lines changed

crates/fluss/src/row/compacted/compacted_row_writer.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ impl CompactedRowWriter {
3333

3434
pub fn new(field_count: usize) -> Self {
3535
// bitset width in bytes, it should be in CompactedRow
36-
let header_size = (field_count + 7) / 8;
36+
let header_size = field_count.div_ceil(8);
3737
let cap = cmp::max(64, header_size);
3838

3939
let mut buffer = BytesMut::with_capacity(cap);
@@ -90,7 +90,7 @@ impl CompactedRowWriter {
9090
}
9191

9292
pub fn write_byte(&mut self, value: u8) {
93-
self.write_raw(&[value as u8]);
93+
self.write_raw(&[value]);
9494
}
9595

9696
pub fn write_binary(&mut self, bytes: &[u8], length: usize) {
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,18 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
4+
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
6+
// "License"); you may not use this file except in compliance
7+
// with the License. You may obtain a copy of the License at
8+
//
9+
// http://www.apache.org/licenses/LICENSE-2.0
10+
//
11+
// Unless required by applicable law or agreed to in writing,
12+
// software distributed under the License is distributed on an
13+
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
// KIND, either express or implied. See the License for the
15+
// specific language governing permissions and limitations
16+
// under the License.
17+
118
mod compacted_row_writer;

0 commit comments

Comments
 (0)