Menu

#90 FOptionContainer.cpp:921: statements in wrong order ?

v2.8
closed
nobody
None
1
2016-07-07
2016-06-30
dcb
No

[FOptionContainer.cpp:921]: (style) Expression is always false because 'else if' condition matches previous condition at line 917.

Source code is

} else if (o.lm.l[list]->blanket_ip_block and ip) {
    return (char*)o.language_list.getTranslation(505);
} else if (o.lm.l[list]->blanketsslblock and ssl) {
    return (char*)o.language_list.getTranslation(506);
} else if (o.lm.l[list]->blanketssl_ip_block and ssl and ip) {

Suggest test more specific things first, not last.

Discussion

  • Nerijus Baliūnas

    Which one matches? For me they are all different.

     
  • dcb

    dcb - 2016-07-07

    Sorry my mistake. No bug here.

     
  • Nerijus Baliūnas

    • status: open --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB