History

netfilter: ipset: add a coding-style fix to ip_set_ext_destroy.

Use a local variable to hold comment in order to align the arguments of ip_set_comment_free properly.

Jeremy Sowden committed 7 years ago

Commit 017f77c1 parent fbe3d0c1 file · +5 −3Browse files

Unified · Split

include/linux/netfilter/ipset/ip_set.h+5−3
@@ -269,9 +269,11 @@ ip_set_ext_destroy(struct ip_set *set, void *data) · 268 unmodified lines
269269 /* Check that the extension is enabled for the set and
270270 * call it's destroy function for its extension part in data.
271271 */
272− if (SET_WITH_COMMENT(set))
273− ip_set_extensions[IPSET_EXT_ID_COMMENT].destroy(
274− set, ext_comment(data, set));
272+ if (SET_WITH_COMMENT(set)) {
273+ struct ip_set_comment *c = ext_comment(data, set);
274+
275+ ip_set_extensions[IPSET_EXT_ID_COMMENT].destroy(set, c);
276+ }
275277 }
276278
277279 static inline int

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t