framebuffer: add sanity check in paintPixel

Origin commit data
------------------
Branch: ni/coolstream
Commit: 5abc54f429
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2012-07-14 (Sat, 14 Jul 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Stefan Seyfried
2012-07-14 21:43:36 +02:00
parent 2afbf5bd01
commit 2e8a236d50

View File

@@ -1279,6 +1279,8 @@ void CFrameBuffer::paintPixel(const int x, const int y, const fb_pixel_t col)
#ifdef USE_NEVIS_GXA
paintHLineRel(x, 1, y, col);
#else
if (x > xRes || y > yRes || x < 0 || y < 0)
return;
fb_pixel_t * pos = getFrameBufferPointer();
pos += (stride / sizeof(fb_pixel_t)) * y;
pos += x;