diff options
author | Jan Engelhardt <jengelh@inai.de> | 2012-09-30 11:23:04 +0200 |
---|---|---|
committer | Jan Engelhardt <jengelh@inai.de> | 2012-09-30 11:23:04 +0200 |
commit | ec40b897289745da3d67de2cb14be30353003922 (patch) | |
tree | 2b9bb5bf0ced141a8b434712eef54d9f0f06adf6 /iptables/iptables.c | |
parent | d637ead63658d741501974c381889b3857073308 (diff) | |
parent | 0d701631625898ac33fb53c67ed2b529668fe0d7 (diff) |
Merge branch 'master' of git://git.inai.de/iptables
Diffstat (limited to 'iptables/iptables.c')
-rw-r--r-- | iptables/iptables.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/iptables/iptables.c b/iptables/iptables.c index 9e3d696a..e935f651 100644 --- a/iptables/iptables.c +++ b/iptables/iptables.c @@ -1295,8 +1295,14 @@ static void command_jump(struct iptables_command_state *cs) cs->target->t = xtables_calloc(1, size); cs->target->t->u.target_size = size; - strcpy(cs->target->t->u.user.name, cs->jumpto); + strcpy(cs->target->t->u.user.name, cs->target->real_name); cs->target->t->u.user.revision = cs->target->revision; + if (cs->target->real_name != cs->target->name) + /* Alias support for userspace side */ + fprintf(stderr, "WARNING: The %s target is obsolete. " + "Use %s instead.\n", + cs->jumpto, cs->target->real_name); + xs_init_target(cs->target); if (cs->target->x6_options != NULL) @@ -1324,8 +1330,12 @@ static void command_match(struct iptables_command_state *cs) size = XT_ALIGN(sizeof(struct xt_entry_match)) + m->size; m->m = xtables_calloc(1, size); m->m->u.match_size = size; - strcpy(m->m->u.user.name, m->name); + strcpy(m->m->u.user.name, m->real_name); m->m->u.user.revision = m->revision; + if (m->real_name != m->name) + fprintf(stderr, "WARNING: The %s match is obsolete. " + "Use %s instead.\n", m->name, m->real_name); + xs_init_match(m); if (m == m->next) return; |