After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 787262 - src/totem-grilo.c:1746: pointless code ?
src/totem-grilo.c:1746: pointless code ?
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: general
unspecified
Other Linux
: Normal minor
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2017-09-04 16:56 UTC by dcb
Modified: 2017-09-08 15:18 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
grilo: Drop redundant if-statement (905 bytes, patch)
2017-09-08 15:18 UTC, Philip Withnall
committed Details | Review

Description dcb 2017-09-04 16:56:31 UTC
../src/totem-grilo.c:1746] -> [../src/totem-grilo.c:1747]: (warning) Opposite inner 'if' condition leads to a dead code block.

Source code is

    for (i = 0; list[i] != NULL; i++) {
        if (list[i] == NULL)
            continue;

Suggest remove pointless if condition.
Comment 1 Philip Withnall 2017-09-08 15:18:22 UTC
The following fix has been pushed:
5610a37 grilo: Drop redundant if-statement
Comment 2 Philip Withnall 2017-09-08 15:18:27 UTC
Created attachment 359404 [details] [review]
grilo: Drop redundant if-statement

As spotted by dcb.

https://bugzilla.gnome.org/show_bug.cgi?id=787262

Signed-off-by: Philip Withnall <withnall@endlessm.com>