FreeBSD Bugzilla – Attachment 129549 Details for
Bug 173543
net/ucarp / vlan interfaces
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
ucarp-1.5.2_2.diff
ucarp-1.5.2_2.diff (text/x-diff; charset=us-ascii), 6.04 KB, created by
Alexey Degtyarev
on 2013-02-06 17:12:31 UTC
(
hide
)
Description:
ucarp-1.5.2_2.diff
Filename:
MIME Type:
Creator:
Alexey Degtyarev
Created:
2013-02-06 17:12:31 UTC
Size:
6.04 KB
patch
obsolete
>diff -Nru ucarp.orig/Makefile ucarp/Makefile >--- ucarp.orig/Makefile 2013-02-06 20:54:57.000000000 +0400 >+++ ucarp/Makefile 2013-02-06 21:04:59.000000000 +0400 >@@ -1,13 +1,9 @@ >-# New ports collection makefile for: ucarp >-# Date created: 2005-05-06 >-# Whom: Meno Abels <meno.abels@adviser.com> >-# >+# Created by: Meno Abels <meno.abels@adviser.com> > # $FreeBSD: head/net/ucarp/Makefile 300897 2012-07-14 14:29:18Z beat $ >-# > > PORTNAME= ucarp > PORTVERSION= 1.5.2 >-PORTREVISION= 1 >+PORTREVISION= 2 > CATEGORIES= net > MASTER_SITES= ftp://ftp.pureftpd.org/pub/pure-ftpd/misc/ucarp/ \ > http://download.pureftpd.org/pub/ucarp/ >@@ -17,9 +13,12 @@ > > USE_BZIP2= yes > >-OPTIONS= UCARP_SCRIPTS "Install scripts to manage virtual IP" on >+OPTIONS_DEFINE= SCRIPTS >+OPTIONS_DEFAULT=SCRIPTS > >-.include <bsd.port.pre.mk> >+SCRIPTS_DESC= Install scripts to manage virtual IP >+ >+.include <bsd.port.options.mk> > > GNU_CONFIGURE= yes > CONFIGURE_ARGS= --disable-nls >@@ -28,7 +27,7 @@ > > PLIST_FILES= sbin/ucarp > >-.if defined(WITH_UCARP_SCRIPTS) >+.if ${PORT_OPTIONS:MSCRIPTS} > PLIST_FILES+= sbin/ucarp-up \ > sbin/ucarp-down > post-install: >@@ -36,4 +35,4 @@ > ${INSTALL_SCRIPT} ${WRKSRC}/examples/bsd/vip-down.sh ${PREFIX}/sbin/ucarp-down > .endif > >-.include <bsd.port.post.mk> >+.include <bsd.port.mk> >diff -Nru ucarp.orig/files/patch-examples:bsd:vip-down.sh ucarp/files/patch-examples:bsd:vip-down.sh >--- ucarp.orig/files/patch-examples:bsd:vip-down.sh 2013-02-06 20:55:19.000000000 +0400 >+++ ucarp/files/patch-examples:bsd:vip-down.sh 1970-01-01 03:00:00.000000000 +0300 >@@ -1,24 +0,0 @@ >---- examples/bsd/vip-down.sh.orig 2006-05-27 20:38:40.000000000 +0000 >-+++ examples/bsd/vip-down.sh 2010-05-30 20:40:19.000000000 +0000 >-@@ -1,4 +1,21 @@ >- #! /bin/sh >-+ >-+if [ -z "$1" -o -z "$2" ]; then >-+ cat <<EOF >-+Usage: ${0##*/} interface virtual-address [if-keep-ip] >-+ interface - interface name where virtual IP-address to be assigned; >-+ virtual-address - virtual IP-address; >-+ if-keep-ip - interface name where virtual IP-address should be kept >-+ when ucarp changes state to BACKUP; >-+ >-+EOF >-+ exit 255 >-+fi >-+ >- exec 2> /dev/null >- >- /sbin/ifconfig "$1" -alias "$2" >-+ >-+if [ ! -z "$3" ]; then >-+ /sbin/ifconfig "$3" alias "$2" netmask 255.255.255.255 >-+fi >diff -Nru ucarp.orig/files/patch-examples:bsd:vip-up.sh ucarp/files/patch-examples:bsd:vip-up.sh >--- ucarp.orig/files/patch-examples:bsd:vip-up.sh 2013-02-06 20:55:13.000000000 +0400 >+++ ucarp/files/patch-examples:bsd:vip-up.sh 1970-01-01 03:00:00.000000000 +0300 >@@ -1,24 +0,0 @@ >---- examples/bsd/vip-up.sh.orig 2006-05-27 20:38:34.000000000 +0000 >-+++ examples/bsd/vip-up.sh 2010-05-30 20:40:19.000000000 +0000 >-@@ -1,4 +1,21 @@ >- #! /bin/sh >-+ >-+if [ -z "$1" -o -z "$2" ]; then >-+ cat <<EOF >-+Usage: ${0##*/} interface virtual-address [if-keep-ip] >-+ interface - interface name where virtual IP-address to be assigned; >-+ virtual-address - virtual IP-address; >-+ if-keep-ip - interface name where virtual IP-address should be kept >-+ when ucarp changes state to BACKUP; >-+ >-+EOF >-+ exit 255 >-+fi >-+ >- exec 2> /dev/null >- >-+if [ ! -z "$3" ]; then >-+ /sbin/ifconfig "$3" -alias "$2" >-+fi >-+ >- /sbin/ifconfig "$1" alias "$2" netmask 255.255.255.255 >diff -Nru ucarp.orig/files/patch-l2vlan ucarp/files/patch-l2vlan >--- ucarp.orig/files/patch-l2vlan 1970-01-01 03:00:00.000000000 +0300 >+++ ucarp/files/patch-l2vlan 2013-02-06 20:31:45.000000000 +0400 >@@ -0,0 +1,14 @@ >+# http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/164060 >+# http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/173543 >+--- src/fillmac.c.orig 2007-07-04 15:34:59.000000000 +0200 >++++ src/fillmac.c 2012-11-11 01:50:29.000000000 +0100 >+@@ -86,7 +86,8 @@ >+ if (strcmp(ifa->ifa_name, interface) == 0 && >+ ifa->ifa_addr->sa_family == AF_LINK) { >+ sadl = (struct sockaddr_dl *) ifa->ifa_addr; >+- if (sadl == NULL || sadl->sdl_type != IFT_ETHER || >++ if (sadl == NULL || ((sadl->sdl_type != IFT_ETHER) && >++ (sadl->sdl_type != IFT_L2VLAN)) || >+ sadl->sdl_alen <= 0) { >+ logfile(LOG_ERR, >+ _("Invalid media / hardware address for [%s]"), >diff -Nru ucarp.orig/files/patch-vip-down ucarp/files/patch-vip-down >--- ucarp.orig/files/patch-vip-down 1970-01-01 03:00:00.000000000 +0300 >+++ ucarp/files/patch-vip-down 2013-02-05 18:57:01.000000000 +0400 >@@ -0,0 +1,24 @@ >+--- examples/bsd/vip-down.sh.orig 2006-05-27 20:38:40.000000000 +0000 >++++ examples/bsd/vip-down.sh 2010-05-30 20:40:19.000000000 +0000 >+@@ -1,4 +1,21 @@ >+ #! /bin/sh >++ >++if [ -z "$1" -o -z "$2" ]; then >++ cat <<EOF >++Usage: ${0##*/} interface virtual-address [if-keep-ip] >++ interface - interface name where virtual IP-address to be assigned; >++ virtual-address - virtual IP-address; >++ if-keep-ip - interface name where virtual IP-address should be kept >++ when ucarp changes state to BACKUP; >++ >++EOF >++ exit 255 >++fi >++ >+ exec 2> /dev/null >+ >+ /sbin/ifconfig "$1" -alias "$2" >++ >++if [ ! -z "$3" ]; then >++ /sbin/ifconfig "$3" alias "$2" netmask 255.255.255.255 >++fi >diff -Nru ucarp.orig/files/patch-vip-up ucarp/files/patch-vip-up >--- ucarp.orig/files/patch-vip-up 1970-01-01 03:00:00.000000000 +0300 >+++ ucarp/files/patch-vip-up 2013-02-05 18:57:01.000000000 +0400 >@@ -0,0 +1,24 @@ >+--- examples/bsd/vip-up.sh.orig 2006-05-27 20:38:34.000000000 +0000 >++++ examples/bsd/vip-up.sh 2010-05-30 20:40:19.000000000 +0000 >+@@ -1,4 +1,21 @@ >+ #! /bin/sh >++ >++if [ -z "$1" -o -z "$2" ]; then >++ cat <<EOF >++Usage: ${0##*/} interface virtual-address [if-keep-ip] >++ interface - interface name where virtual IP-address to be assigned; >++ virtual-address - virtual IP-address; >++ if-keep-ip - interface name where virtual IP-address should be kept >++ when ucarp changes state to BACKUP; >++ >++EOF >++ exit 255 >++fi >++ >+ exec 2> /dev/null >+ >++if [ ! -z "$3" ]; then >++ /sbin/ifconfig "$3" -alias "$2" >++fi >++ >+ /sbin/ifconfig "$1" alias "$2" netmask 255.255.255.255
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 173543
:
129548
| 129549