diff --git a/oss-internship-2020/libtiff/example/main_sandboxed.cc b/oss-internship-2020/libtiff/example/main_sandboxed.cc index 3dfbfdd..b9c7698 100644 --- a/oss-internship-2020/libtiff/example/main_sandboxed.cc +++ b/oss-internship-2020/libtiff/example/main_sandboxed.cc @@ -60,7 +60,7 @@ absl::Status CheckCluster(uint32_t cluster, if (buffer.GetSize() <= cluster * kClusterSize) { return absl::InternalError("Buffer overrun\n"); } - auto target = buffer.GetData() + cluster * kClusterSize; + auto* target = buffer.GetData() + cluster * kClusterSize; if (!std::memcmp(target, expected_cluster.data(), kClusterSize)) { return absl::OkStatus(); @@ -80,7 +80,7 @@ absl::Status CheckRgbPixel(uint32_t pixel, const ChannelLimits& limits, if (buffer.GetSize() <= pixel * kChannelsInPixel) { return absl::InternalError("Buffer overrun\n"); } - auto rgb = buffer.GetData() + kChannelsInPixel * pixel; + auto* rgb = buffer.GetData() + kChannelsInPixel * pixel; if (rgb[0] >= limits.min_red && rgb[0] <= limits.max_red && rgb[1] >= limits.min_green && rgb[1] <= limits.max_green && @@ -104,7 +104,7 @@ absl::Status CheckRgbaPixel(uint32_t pixel, const ChannelLimits& limits, return absl::InternalError("Buffer overrun\n"); } - auto rgba = buffer[adjusted_pixel]; + auto* rgba = buffer[adjusted_pixel]; if (TIFFGetR(rgba) >= static_cast(limits.min_red) && TIFFGetR(rgba) <= static_cast(limits.max_red) && TIFFGetG(rgba) >= static_cast(limits.min_green) && diff --git a/oss-internship-2020/libtiff/test/raw_decode.cc b/oss-internship-2020/libtiff/test/raw_decode.cc index dbf8638..36bf842 100644 --- a/oss-internship-2020/libtiff/test/raw_decode.cc +++ b/oss-internship-2020/libtiff/test/raw_decode.cc @@ -64,7 +64,7 @@ bool CheckCluster(uint32_t cluster, const sapi::v::Array& buffer, return true; } - auto target = buffer.GetData() + cluster * kClusterSize; + auto* target = buffer.GetData() + cluster * kClusterSize; bool comp = !(std::memcmp(target, expected_cluster.data(), kClusterSize) == 0); @@ -89,7 +89,7 @@ bool CheckRgbPixel(uint32_t pixel, const ChannelLimits& limits, return true; } - auto rgb = buffer.GetData() + pixel * kChannelsInPixel; + auto* rgb = buffer.GetData() + pixel * kChannelsInPixel; bool comp = !(rgb[0] >= limits.min_red && rgb[0] <= limits.max_red && rgb[1] >= limits.min_green && rgb[1] <= limits.max_green && rgb[2] >= limits.min_blue && rgb[2] <= limits.max_blue); @@ -115,7 +115,7 @@ bool CheckRgbaPixel(uint32_t pixel, const ChannelLimits& limits, return true; } - auto rgba = buffer[adjusted_pixel]; + auto* rgba = buffer[adjusted_pixel]; bool comp = !(TIFFGetR(rgba) >= static_cast(limits.min_red) && TIFFGetR(rgba) <= static_cast(limits.max_red) && TIFFGetG(rgba) >= static_cast(limits.min_green) &&