mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-21 21:33:54 +00:00
Merge pull request #1413 from TomHarte/ShakerScanTarget
Avoid taking an out-of-range pointer.
This commit is contained in:
commit
f00e7c4a80
@ -76,7 +76,7 @@ struct ScanTarget: public Outputs::Display::ScanTarget {
|
|||||||
x_ = 0;
|
x_ = 0;
|
||||||
} break;
|
} break;
|
||||||
case Event::EndVerticalRetrace:
|
case Event::EndVerticalRetrace:
|
||||||
std::fill(&raw_image_[line_ * ImageWidth], &raw_image_[ImageHeight * ImageWidth], 0);
|
std::fill(raw_image_.begin() + (line_ * ImageWidth), raw_image_.end(), 0);
|
||||||
line_ = 0;
|
line_ = 0;
|
||||||
x_ = 0;
|
x_ = 0;
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user