git: 24e8ed535ff6 - main - network.subr: correct return code in case of bad call to ifisup()

From: Eugene Grosbein <eugen_at_FreeBSD.org>
Date: Tue, 01 Jul 2025 14:35:44 UTC
The branch main has been updated by eugen:

URL: https://cgit.FreeBSD.org/src/commit/?id=24e8ed535ff673b9ea751c3d3b2a68ef0a29b0e2

commit 24e8ed535ff673b9ea751c3d3b2a68ef0a29b0e2
Author:     Eugene Grosbein <eugen@FreeBSD.org>
AuthorDate: 2025-07-01 14:33:19 +0000
Commit:     Eugene Grosbein <eugen@FreeBSD.org>
CommitDate: 2025-07-01 14:33:19 +0000

    network.subr: correct return code in case of bad call to ifisup()
    
    This is rather cosmetic correction.
    
    PR:             287872
    MFC-after:      2 weeks
    X-MFC-With:     6d3bc576abbd84f736d917f5bfec4e3fe7e6c125
---
 libexec/rc/network.subr | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libexec/rc/network.subr b/libexec/rc/network.subr
index 2113a3f66f0f..5e4f2c1f39a0 100644
--- a/libexec/rc/network.subr
+++ b/libexec/rc/network.subr
@@ -661,7 +661,7 @@ ifisup()
 {
 	local _if
 
-	[ -z "$1" ] && return 1
+	[ -z "$1" ] && return 2
 	_if="$1"
 
 	set -- $(${IFCONFIG_CMD} -n ${_if} 2>/dev/null)