Index: media/capture/video/win/video_capture_device_mf_win.cc |
diff --git a/media/capture/video/win/video_capture_device_mf_win.cc b/media/capture/video/win/video_capture_device_mf_win.cc |
index 95595bd16b2e85c313177732a8b2e8c466b82308..77f54f8b9acd34873638ba693d6161f98ec07335 100644 |
--- a/media/capture/video/win/video_capture_device_mf_win.cc |
+++ b/media/capture/video/win/video_capture_device_mf_win.cc |
@@ -171,9 +171,9 @@ bool VideoCaptureDeviceMFWin::FormatFromGuid(const GUID& guid, |
{MFVideoFormat_YV12, PIXEL_FORMAT_YV12}, |
}; |
- for (int i = 0; i < arraysize(kFormatMap); ++i) { |
- if (kFormatMap[i].guid == guid) { |
- *format = kFormatMap[i].format; |
+ for (const auto& kFormat : kFormatMap) { |
+ if (kFormat.guid == guid) { |
+ *format = kFormat.format; |
return true; |
} |
} |