Don't do anything if the interface doesn't exist
iproute2_post_stop() does now check if the network interface still exist. Reported-by: Yun Zheng Hu <hu@fox-it.com> X-Gentoo-Bug: 379575 X-Gentoo-Bug-URL: https://bugs.gentoo.org/379575
This commit is contained in:
parent
fb485366e6
commit
bf49e59e3e
@ -301,6 +301,9 @@ iproute2_post_start()
|
|||||||
|
|
||||||
iproute2_post_stop()
|
iproute2_post_stop()
|
||||||
{
|
{
|
||||||
|
# Only do something if the interface actually exist
|
||||||
|
_exists || return
|
||||||
|
|
||||||
# Kernel may not have IP built in
|
# Kernel may not have IP built in
|
||||||
if [ -e /proc/net/route ]; then
|
if [ -e /proc/net/route ]; then
|
||||||
local rules="$(service_get_value "ip_rule")"
|
local rules="$(service_get_value "ip_rule")"
|
||||||
|
Loading…
Reference in New Issue
Block a user