diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2025-05-21 05:53:25 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2025-05-21 05:53:25 (GMT) |
commit | 2258d4254612399ac1a3e7597a39a1bc83c155ff (patch) | |
tree | df5e7e6d21e0cd0779a0619ea9beb0e68bcb0221 | |
parent | abb14c9aa734040d0b164d317cd5021633614e57 (diff) |
Fix compilation in non-NDEBUG mode.
-rw-r--r-- | src/glibext/widthtracker.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/glibext/widthtracker.c b/src/glibext/widthtracker.c index 7e06578..0a3dbe6 100644 --- a/src/glibext/widthtracker.c +++ b/src/glibext/widthtracker.c @@ -330,13 +330,17 @@ void g_width_tracker_set_column_min_width(GWidthTracker *tracker, size_t col, in void g_width_tracker_compute_width(const GWidthTracker *tracker, int *width) { + size_t col_count; /* Nombre maximum de colonnes */ size_t i; /* Boucle de parcours */ *width = 0; - // FIX access to col_count - for (i = 0; i < tracker->col_count; i++) + + col_count = tracker->opt_count + tracker->reg_count; + + + for (i = 0; i < col_count; i++) *width += tracker->min_widths[i]; } |