1

There are some strange code:

    if ifup -a --exclude=lo; then
        log_action_end_msg $?
    else
        log_action_end_msg $?
    fi

both variants have exactly same code:

        log_action_end_msg $?

Why need "if", "then", "else", "fi"? Why not simple:

    ifup -a --exclude=lo
    log_action_end_msg $?

There are 3 times such code in this file.

This file belongs to "netbase" 4.35ubuntu3

1
  • logically it is the same
    – yossile
    Mar 25, 2012 at 13:26

1 Answer 1

0

You are right that the if statement appears to be unnecessary. My guess is that the two branches of the if statement did different things in an older version, but the two branches were modified to their current form at some point.

If it bothers you, I'd suggest filing a bug.

1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .