diff options
Diffstat (limited to 'plugingui')
-rw-r--r-- | plugingui/painter.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/plugingui/painter.cc b/plugingui/painter.cc index 3c290f3..3e6fa48 100644 --- a/plugingui/painter.cc +++ b/plugingui/painter.cc @@ -54,7 +54,10 @@ void Painter::setColour(const Colour& colour) static void plot(PixelBufferAlpha& pixbuf, const Colour& colour, int x, int y, double c) { - if((x >= (int)pixbuf.width) || (y >= (int)pixbuf.height)) + if((x >= (int)pixbuf.width) || + (y >= (int)pixbuf.height) || + (x < 0) || + (y < 0)) { return; } |