From a42142d5a0671c3c40c13a942d9fb3a21497c4b9 Mon Sep 17 00:00:00 2001 From: Jehan Date: Mon, 28 Oct 2024 16:17:45 +0100 Subject: [PATCH] libgimpwidgets: delete unused variable. Checking the log, it looks like this code has not been touched since 2007, so whatever this various was used for, it's clearly not been used for a long time. Fixes warning: > libgimpwidgets/gimpcairo-utils.c:80:16: warning: variable 'total_length' set but not used [-Wunused-but-set-variable] --- libgimpwidgets/gimpcairo-utils.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/libgimpwidgets/gimpcairo-utils.c b/libgimpwidgets/gimpcairo-utils.c index c36b150838..d910ab243b 100644 --- a/libgimpwidgets/gimpcairo-utils.c +++ b/libgimpwidgets/gimpcairo-utils.c @@ -77,14 +77,10 @@ gimp_cairo_set_focus_line_pattern (cairo_t *cr, */ gint n_dashes = strlen ((const gchar *) dash_list); gdouble *dashes = g_new (gdouble, n_dashes); - gdouble total_length = 0; gint i; for (i = 0; i < n_dashes; i++) - { - dashes[i] = dash_list[i]; - total_length += dash_list[i]; - } + dashes[i] = dash_list[i]; cairo_set_dash (cr, dashes, n_dashes, 0.5);