Cppcheck fixes

(cherry picked from commit 3e35fe4d80)

# Conflicts:
#	app/widgets/gimpcolordialog.c
#	libgimpwidgets/gimpchainbutton.c
This commit is contained in:
Rafał Mikrut
2020-11-03 06:35:54 +01:00
committed by Jacob Boerema
parent dda9339969
commit bfc59da987
3 changed files with 4 additions and 4 deletions

View File

@ -382,7 +382,7 @@ pattern_to_attrs (const gchar *text,
while (TRUE) while (TRUE)
{ {
while (*p && *q && *q != '_') while (*p && q && *q != '_')
{ {
p = g_utf8_next_char (p); p = g_utf8_next_char (p);
q++; q++;

View File

@ -884,8 +884,8 @@ fli_write_lc (FILE *f,
while (xc < fli_header->width) while (xc < fli_header->width)
{ {
sc = 0; sc = 0;
while ((linebuf[xc] == old_linebuf[xc]) && while ((xc < fli_header->width) &&
(xc < fli_header->width) && (linebuf[xc] == old_linebuf[xc]) &&
(sc < 255)) (sc < 255))
{ {
xc++; xc++;

View File

@ -147,7 +147,7 @@ d_paint_circle (GfigObject *obj)
gdouble angle = 0; gdouble angle = 0;
gint i = 0; gint i = 0;
while (i < 362) while (i < 361)
{ {
static const gdouble step = 2 * G_PI / 180; static const gdouble step = 2 * G_PI / 180;