Skip to content

Commit 9829467

Browse files
authored
Fix some ubsan issues related to double vs ui64 (#13364)
1 parent e3df206 commit 9829467

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ydb/core/sys_view/service/ext_counters.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ class TExtCountersUpdaterActor
177177
ExecuteLatencyMsPrevValues[n] = value;
178178
if (ExecuteLatencyMsBounds[n] == 0) {
179179
NMonitoring::TBucketBound bound = snapshot->UpperBound(n);
180-
ExecuteLatencyMsBounds[n] = bound == Max<NMonitoring::TBucketBound>() ? Max<ui64>() : bound;
180+
ExecuteLatencyMsBounds[n] = bound == Max<NMonitoring::TBucketBound>() ? Max<ui64>() : ui64(bound);
181181
}
182182
}
183183
metrics->AddMetric("queries.requests", total);

ydb/core/tablet_flat/ut/ut_stat.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -746,7 +746,7 @@ Y_UNIT_TEST_SUITE(BuildStatsHistogram) {
746746

747747
ui32 operator()(const TRow&) noexcept
748748
{
749-
auto x = Random.Uniform(1 << Buckets);
749+
auto x = Random.Uniform(1, 1 << Buckets);
750750
return Min(ui32(log2(x)), Buckets - 1);
751751
}
752752

0 commit comments

Comments
 (0)