ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/src/trunk/sbin/ipfw/ipv6.c
(Generate patch)

Comparing trunk/sbin/ipfw/ipv6.c (file contents):
Revision 11207 by laffer1, Fri Sep 30 01:26:12 2016 UTC vs.
Revision 11208 by laffer1, Sun Jul 1 20:44:37 2018 UTC

# Line 1 | Line 1
1 + /* $MidnightBSD$ */
2   /*
3   * Copyright (c) 2002-2003 Luigi Rizzo
4   * Copyright (c) 1996 Alex Nash, Paul Traina, Poul-Henning Kamp
# Line 17 | Line 18
18   *
19   * NEW command line interface for IP firewall facility
20   *
21 < * $MidnightBSD$
21 > * $FreeBSD: stable/10/sbin/ipfw/ipv6.c 318271 2017-05-14 13:59:40Z marius $
22   *
23   * ipv6 support
24   */
# Line 338 | Line 339 | fill_ip6(ipfw_insn_ip6 *cmd, char *av, int cblen)
339   {
340          int len = 0;
341          struct in6_addr *d = &(cmd->addr6);
342 +        char *oav;
343          /*
344           * Needed for multiple address.
345           * Note d[1] points to struct in6_add r mask6 of cmd
# Line 375 | Line 377 | fill_ip6(ipfw_insn_ip6 *cmd, char *av, int cblen)
377                  return (1);
378          }
379  
380 <        av = strdup(av);
380 >        oav = av = strdup(av);
381          while (av) {
382                  /*
383                   * After the address we can have '/' indicating a mask,
# Line 451 | Line 453 | fill_ip6(ipfw_insn_ip6 *cmd, char *av, int cblen)
453          if (len + 1 > F_LEN_MASK)
454                  errx(EX_DATAERR, "address list too long");
455          cmd->o.len |= len+1;
456 <        free(av);
456 >        free(oav);
457          return (1);
458   }
459  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines