Skip to content
This repository was archived by the owner on Jul 31, 2023. It is now read-only.

Commit 9a508e8

Browse files
authored
Fix nits. (#423)
* Fix order of args to string constructor. * Fix fuzzer.
1 parent b14a5c0 commit 9a508e8

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

opencensus/tags/internal/grpc_tags_bin_fuzzer.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, size_t Size) {
1919
absl::string_view input(reinterpret_cast<const char *>(Data), Size);
20-
TagMap m({});
20+
opencensus::tags::TagMap m({});
2121
opencensus::tags::propagation::FromGrpcTagsBinHeader(input, &m);
2222
return 0;
2323
}

opencensus/tags/internal/grpc_tags_bin_test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ TEST(GrpcTagsBinTest, SerializeTooLong) {
147147
int key_n = 0;
148148
while (out_len < 8192) {
149149
const std::string k = absl::StrCat("key_", key_n++);
150-
tags.emplace_back(TagKey::Register(k), std::string('A', kValLen));
150+
tags.emplace_back(TagKey::Register(k), std::string(kValLen, 'A'));
151151
out_len += 1 + 1 + k.size() + 1 + kValLen;
152152
}
153153
TagMap m(std::move(tags));

tools/fuzz.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ set -e
2222
set -x
2323
cmake -H. -B.build -DBUILD_TESTING=OFF -DCMAKE_CXX_COMPILER=clang-6.0 \
2424
-DFUZZER=-fsanitize=fuzzer \
25-
-DCMAKE_CXX_FLAGS="-fsanitize=fuzzer-no-link,address -g -O2 -fno-exceptions"
25+
-DCMAKE_CXX_FLAGS="-fsanitize=fuzzer-no-link,address -g -O2"
2626
cmake --build .build
2727
./.build/opencensus/tags/opencensus_tags_grpc_tags_bin_fuzzer \
2828
opencensus/tags/internal/grpc_tags_bin_corpus -runs=0

0 commit comments

Comments
 (0)