cql3: remove unnecessary assert()
In cql3/, there was one call to assert() (not SCYLLA_ASSERT or
throwing_assert), and it was:
const auto shard_num = smp::count;
assert(shard_num > 0)
Rather than converting this assert() to throwing_assert() as I did in
previous patches, I decided to outright remove it: Seastar guarantees
that smp::count is not zero. Many other places in the code use
smp::count assuming that it is correct, no other place bothers to assert
it isn't zero.
Signed-off-by: Nadav Har'El <nyh@scylladb.com>
This commit is contained in:
@@ -371,7 +371,6 @@ process_forced_rebounce(unsigned shard, query_processor& qp, const query_options
|
||||
// On the last iteration, re-bounce to the correct shard.
|
||||
if (counter != 0) {
|
||||
const auto shard_num = smp::count;
|
||||
assert(shard_num > 0);
|
||||
const auto local_shard = this_shard_id();
|
||||
auto target_shard = local_shard + 1;
|
||||
if (target_shard == shard) {
|
||||
|
||||
Reference in New Issue
Block a user