diff options
| author | 2018-12-11 18:12:27 -0800 | |
|---|---|---|
| committer | 2018-12-11 18:12:27 -0800 | |
| commit | 79f2f05c603525149e52848fa4a56b6c8a8c4880 (patch) | |
| tree | 1d76f713c1b95f055ee4b31cad05ac8491d0047f /libs/gui/bufferqueue | |
| parent | d41436e4fc7cb1bbca05fcb7074e9eb3cabe6120 (diff) | |
| parent | a5466b2ac77abc0d4dab63813be479cd8e26dd3f (diff) | |
Merge "Fix performance-for-range-copy warnings" am: 10a6a9f071 am: 6687474dc6
am: a5466b2ac7
Change-Id: Ic04a1ddf25643fe836cc15a59c7f61fe6b6e8f00
Diffstat (limited to 'libs/gui/bufferqueue')
| -rw-r--r-- | libs/gui/bufferqueue/1.0/H2BGraphicBufferProducer.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/gui/bufferqueue/1.0/H2BGraphicBufferProducer.cpp b/libs/gui/bufferqueue/1.0/H2BGraphicBufferProducer.cpp index 8af1a67f12..e64ba9bcdd 100644 --- a/libs/gui/bufferqueue/1.0/H2BGraphicBufferProducer.cpp +++ b/libs/gui/bufferqueue/1.0/H2BGraphicBufferProducer.cpp @@ -901,7 +901,7 @@ inline bool convertTo( int const* constFds = static_cast<int const*>(baseFds.get()); numFds = baseNumFds; if (l->unflatten(constBuffer, size, constFds, numFds) != NO_ERROR) { - for (auto nhA : nhAA) { + for (const auto& nhA : nhAA) { for (auto nh : nhA) { if (nh != nullptr) { native_handle_close(nh); @@ -912,8 +912,8 @@ inline bool convertTo( return false; } - for (auto nhA : nhAA) { - for (auto nh : nhA) { + for (const auto& nhA : nhAA) { + for (const auto& nh : nhA) { if (nh != nullptr) { native_handle_delete(nh); } |