gtkthemingengine: Fix a definite use of an uninitialised variable
At this point, segments[1] is always uninitialised, and is used to initialise itself. Looking at the code in the branch above, this appears to have been a typo from segments[0], as segments[1] seems to typically be 2 * segments[0]. Found by scan-build. https://bugzilla.gnome.org/show_bug.cgi?id=712760
This commit is contained in:
@@ -1478,7 +1478,7 @@ set_stroke_style (cairo_t *cr,
|
||||
n = round ((1. / 3) * n);
|
||||
|
||||
segments[0] = n ? (1. / 3) * length / n : 1;
|
||||
segments[1] = 2 * segments[1];
|
||||
segments[1] = 2 * segments[0];
|
||||
}
|
||||
cairo_set_dash (cr, segments, G_N_ELEMENTS (segments), 0);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user