Implemented some suggestions from clang-tidy (part 9) [#CLICKHOUSE-3301].

This commit is contained in:
Alexey Milovidov 2017-09-08 08:03:21 +03:00
parent dc4976f562
commit a81028377e
2 changed files with 5 additions and 5 deletions

View File

@ -13,10 +13,10 @@ int main(int argc, char ** argv)
{
std::string test1 = "kjhsgdfkjhg2378rtzgvxkz877%^&^*%&^*&*";
std::string test2 = "{\"asd\" = \"qw1\",\"qwe24\" = \"3asd\"}";
test2[test2.find("1")] = char(127 + 64);
test2[test2.find("2")] = char(127 + 64 + 32);
test2[test2.find("3")] = char(127 + 64 + 32 + 16);
test2[test2.find("4")] = char(127 + 64 + 32 + 16 + 8);
test2[test2.find('1')] = char(127 + 64);
test2[test2.find('2')] = char(127 + 64 + 32);
test2[test2.find('3')] = char(127 + 64 + 32 + 16);
test2[test2.find('4')] = char(127 + 64 + 32 + 16 + 8);
std::string str;
{

View File

@ -33,7 +33,7 @@ int main(int argc, const char ** argv)
UInt64 size = Poco::File(argv[1]).getSize();
UInt64 pos = 0;
DB::ReadBufferFromFile in(argv[1], buf_size);
char * buf = new char[block];
auto buf = std::make_unique<char[]>(block);
int checksum = 0;
UInt64 bytes_read = 0;