platform: merge _add_action(), _add_action_simple() and _add_action_mirred()...
platform: merge _add_action(), _add_action_simple() and _add_action_mirred() into _nl_msg_new_tfilter() There is only one caller, hence it's simpler to see it all in one place. I prefer this, because then I can read the code top to bottom and see what's happening, without following helper functions. Also, this way we can "reuse" the nla_put_failure label and assertion. Previously, if the assertion was hit we would not rewind the buffer but continue constructing the message (which is already borked). Not that it matters too much, because this was on an "failed-assertion" code path.
Showing with 46 additions and 79 deletions