Skip to content

Commit ff2c7ea

Browse files
committed
fix trace source validation
1 parent 3ae4854 commit ff2c7ea

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

src/datadog/trace_source.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,7 @@ bool validate_trace_source(StringView source_str) {
1111
auto maybe_ts_uint = parse_uint64(source_str, 10);
1212
if (maybe_ts_uint.if_error()) return false;
1313

14-
// Bit twiddling magic is coming from
15-
// <http://www.graphics.stanford.edu/~seander/bithacks.html> <3.
16-
auto is_power_of_2 = [](uint64_t v) -> bool { return v && !(v & (v - 1)); };
17-
18-
return is_power_of_2(*maybe_ts_uint);
14+
return true;
1915
}
2016

2117
} // namespace tracing

0 commit comments

Comments
 (0)