svn commit: r368492 - head/sbin/ifconfig
Hans Petter Selasky
hps at selasky.org
Wed Dec 9 20:47:13 UTC 2020
On 12/9/20 9:19 PM, Hans Petter Selasky wrote:
> On 12/9/20 9:13 PM, Hans Petter Selasky wrote:
>> because the date pointed
>
> because the data pointed
> ^^ spelling fix
Just a heads up: I plan on making this a separate direct-commit to
12-stable tomorrow, because this change depends on, r366917, stacked
VLANs, which I have no intention of MFC'ing.
The fix for 12-stable looks like this:
> Index: sbin/ifconfig/ifclone.c
> ===================================================================
> --- sbin/ifconfig/ifclone.c (revision 368297)
> +++ sbin/ifconfig/ifclone.c (working copy)
> @@ -124,6 +124,7 @@
> struct ifreq ifr;
> struct clone_defcb *dcp;
> clone_callback_func *clone_cb = NULL;
> + const char *ifr_name = strchr(name, '.') ? "vlan" : name;
>
> memset(&ifr, 0, sizeof(ifr));
> (void) strlcpy(ifr.ifr_name, name, sizeof(ifr.ifr_name));
> @@ -131,7 +132,7 @@
> if (clone_cb == NULL) {
> /* Try to find a default callback */
> SLIST_FOREACH(dcp, &clone_defcbh, next) {
> - if (strncmp(dcp->ifprefix, ifr.ifr_name,
> + if (strncmp(dcp->ifprefix, ifr_name,
> strlen(dcp->ifprefix)) == 0) {
> clone_cb = dcp->clone_cb;
> break;
--HPS
More information about the svn-src-all
mailing list