newsboat / stfl

stfl with Newsboat-related bugfixes
GNU Lesser General Public License v3.0
7 stars 3 forks source link

Fix indentation warning #3

Closed Minoru closed 2 years ago

Minoru commented 2 years ago

On 127c0b22fcb3cef5bd940a2abe515e13a0afc126, with GCC 10.2.1 when running make:

widgets/wt_list.c: In function ‘fix_offset_pos’:
widgets/wt_list.c:76:3: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
   76 |   if (stfl_widget_getkv_int(c, L"can_focus", 1) &&
      |   ^~
widgets/wt_list.c:79:4: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
   79 |    latest_widget = c;
      |    ^~~~~~~~~~~~~

Looks like a mistake in https://github.com/newsboat/stfl/commit/0cc16e7d2784d3946c2da6cb83c78abe8dbc975c?

cc @dennisschagt

dennisschagt commented 2 years ago

Looks like a mistake in 0cc16e7?

Jup, looks like a mistake.

I don't think it has any effect on Newsboat because we don't use any hidden or non-focusable lines in the listviews. However, I will create a PR to fix this.

Minoru commented 2 years ago

Ah, cool. Thank you!