Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tabs and lint-ignores #6734

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions db/log_reader.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ class Reader {
//
// If "checksum" is true, verify checksums if available.
Reader(std::shared_ptr<Logger> info_log,
// @lint-ignore TXT2 T25377293 Grandfathered in
std::unique_ptr<SequentialFileReader>&& file, Reporter* reporter,
bool checksum, uint64_t log_num);
// No copying allowed
Expand Down Expand Up @@ -159,7 +158,6 @@ class Reader {
class FragmentBufferedReader : public Reader {
public:
FragmentBufferedReader(std::shared_ptr<Logger> info_log,
// @lint-ignore TXT2 T25377293 Grandfathered in
std::unique_ptr<SequentialFileReader>&& _file,
Reporter* reporter, bool checksum, uint64_t log_num)
: Reader(info_log, std::move(_file), reporter, checksum, log_num),
Expand Down
5 changes: 2 additions & 3 deletions java/rocksjni/jnicallback.cc
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,10 @@ JniCallback::~JniCallback() {
JNIEnv* env = getJniEnv(&attached_thread);
assert(env != nullptr);

if(m_jcallback_obj != nullptr) {
if (m_jcallback_obj != nullptr) {
env->DeleteGlobalRef(m_jcallback_obj);
}

releaseJniEnv(attached_thread);
}
// @lint-ignore TXT4 T25377293 Grandfathered in
} // namespace ROCKSDB_NAMESPACE
} // namespace ROCKSDB_NAMESPACE
1 change: 0 additions & 1 deletion java/rocksjni/jnicallback.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,4 @@ class JniCallback {
};
} // namespace ROCKSDB_NAMESPACE

// @lint-ignore TXT4 T25377293 Grandfathered in
#endif // JAVA_ROCKSJNI_JNICALLBACK_H_
3 changes: 1 addition & 2 deletions java/rocksjni/rocks_callback_object.cc
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,4 @@ void Java_org_rocksdb_RocksCallbackObject_disposeInternal(JNIEnv* /*env*/,
// I think this is okay, as Comparator and JniCallback both have virtual
// destructors...
delete reinterpret_cast<ROCKSDB_NAMESPACE::JniCallback*>(handle);
// @lint-ignore TXT4 T25377293 Grandfathered in
}
}
3 changes: 1 addition & 2 deletions java/rocksjni/statisticsjni.cc
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,4 @@ bool StatisticsJni::HistEnabledForType(uint32_t type) const {

return true;
}
// @lint-ignore TXT4 T25377293 Grandfathered in
}; // namespace ROCKSDB_NAMESPACE
} // namespace ROCKSDB_NAMESPACE
3 changes: 1 addition & 2 deletions java/rocksjni/statisticsjni.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,4 @@ class StatisticsJni : public StatisticsImpl {

} // namespace ROCKSDB_NAMESPACE

// @lint-ignore TXT4 T25377293 Grandfathered in
#endif // JAVA_ROCKSJNI_STATISTICSJNI_H_
#endif // JAVA_ROCKSJNI_STATISTICSJNI_H_
7 changes: 3 additions & 4 deletions table/cuckoo/cuckoo_table_builder_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,9 @@ class CuckooBuilderTest : public testing::Test {
uint64_t read_file_size;
ASSERT_OK(env_->GetFileSize(fname, &read_file_size));

// @lint-ignore TXT2 T25377293 Grandfathered in
Options options;
options.allow_mmap_reads = true;
ImmutableCFOptions ioptions(options);
Options options;
options.allow_mmap_reads = true;
ImmutableCFOptions ioptions(options);

// Assert Table Properties.
TableProperties* props = nullptr;
Expand Down
16 changes: 8 additions & 8 deletions util/crc32c.cc
Original file line number Diff line number Diff line change
Expand Up @@ -725,29 +725,29 @@ uint32_t crc32c_3way(uint32_t crc, const char* buf, size_t len) {
do {
// jumps here for a full block of len 128
CRCtriplet(crc, next, -128);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 127:
// jumps here or below for the first block smaller
CRCtriplet(crc, next, -127);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 126:
CRCtriplet(crc, next, -126); // than 128
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 125:
CRCtriplet(crc, next, -125);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 124:
CRCtriplet(crc, next, -124);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 123:
CRCtriplet(crc, next, -123);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 122:
CRCtriplet(crc, next, -122);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 121:
CRCtriplet(crc, next, -121);
FALLTHROUGH_INTENDED;
FALLTHROUGH_INTENDED;
case 120:
CRCtriplet(crc, next, -120);
FALLTHROUGH_INTENDED;
Expand Down
2 changes: 1 addition & 1 deletion utilities/merge_operators/bytesxor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ void BytesXOROperator::XOR(const Slice* existing_value,
new_value->push_back(existing_value_data[i]);
}
} else {
assert(value.size() == max_size);
assert(value.size() == max_size);
for (size_t i = min_size; i < max_size; i++) {
new_value->push_back(value_data[i]);
}
Expand Down
3 changes: 1 addition & 2 deletions utilities/simulator_cache/sim_cache.cc
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ class CacheActivityLogger {
log_line += key.ToString(true);
log_line += " - ";
AppendNumberTo(&log_line, size);
// @lint-ignore TXT2 T25377293 Grandfathered in
log_line += "\n";
log_line += "\n";

// line format: "ADD - <KEY> - <KEY-SIZE>"
MutexLock l(&mutex_);
Expand Down
7 changes: 3 additions & 4 deletions utilities/simulator_cache/sim_cache_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -199,8 +199,7 @@ TEST_F(SimCacheTest, SimCacheLogging) {
ASSERT_EQ(add_num, num_block_entries);

// Log things again but stop logging automatically after reaching 512 bytes
// @lint-ignore TXT2 T25377293 Grandfathered in
int max_size = 512;
int max_size = 512;
ASSERT_OK(sim_cache->StartActivityLogging(log_file, env_, max_size));
for (int it = 0; it < 10; it++) {
for (int i = 0; i < num_block_entries; i++) {
Expand All @@ -211,9 +210,9 @@ TEST_F(SimCacheTest, SimCacheLogging) {

uint64_t fsize = 0;
ASSERT_OK(env_->GetFileSize(log_file, &fsize));
// error margin of 100 bytes
// error margin of 100 bytes
ASSERT_LT(fsize, max_size + 100);
ASSERT_GT(fsize, max_size - 100);
ASSERT_GT(fsize, max_size - 100);
}

} // namespace ROCKSDB_NAMESPACE
Expand Down
3 changes: 1 addition & 2 deletions utilities/ttl/ttl_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -668,8 +668,7 @@ TEST_F(TtlTest, ChangeTtlOnOpenDb) {

OpenTtl(1); // T=0:Open the db with ttl = 2
SetTtl(3);
// @lint-ignore TXT2 T25377293 Grandfathered in
PutValues(0, kSampleSize_); // T=0:Insert Set1. Delete at t=2
PutValues(0, kSampleSize_); // T=0:Insert Set1. Delete at t=2
SleepCompactCheck(2, 0, kSampleSize_, true); // T=2:Set1 should be there
CloseTtl();
}
Expand Down