diff options
author | Matthias Clasen <mclasen@redhat.com> | 2005-08-19 16:16:17 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2005-08-19 16:16:17 +0000 |
commit | e20eb8b760fc6c914d785de62e04bd93e5cc6dfa (patch) | |
tree | fe3c7b35819b9fd61577de16a1f0679ecf59c779 /gtk/gtkhsv.c | |
parent | 445b61e3e7419f1c279df7850b7ddebec48a582c (diff) | |
download | gtk+-e20eb8b760fc6c914d785de62e04bd93e5cc6dfa.tar.gz |
Avoid a buffer overrun. (#313900, Sebastien Bacher)
2005-08-19 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkhsv.c (paint_triangle): Avoid a buffer overrun.
(#313900, Sebastien Bacher)
Diffstat (limited to 'gtk/gtkhsv.c')
-rw-r--r-- | gtk/gtkhsv.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk/gtkhsv.c b/gtk/gtkhsv.c index e3ea349662..fcd5d53578 100644 --- a/gtk/gtkhsv.c +++ b/gtk/gtkhsv.c @@ -1201,7 +1201,7 @@ paint_triangle (GtkHSV *hsv, for (xx = x; xx < x_start; xx++) *p++ = c; - for (xx = x_start; xx < x_end; xx++) + for (; xx < x_end; xx++) { x_interp = CLAMP (xx, xl, xr); @@ -1212,7 +1212,7 @@ paint_triangle (GtkHSV *hsv, c = (rr << 16) | (gr << 8) | br; - for (xx = x_end; xx < x + width; xx++) + for (; xx < x + width; xx++) *p++ = c; } } |