* [git.ipfire.org] IPFire 2.x development tree branch, next, updated. a83bcf914c9214d522d99966386c0a989c651f0f
@ 2020-01-25 21:23 Arne Fitzenreiter
0 siblings, 0 replies; only message in thread
From: Arne Fitzenreiter @ 2020-01-25 21:23 UTC (permalink / raw)
To: ipfire-scm
[-- Attachment #1: Type: text/plain, Size: 2302 bytes --]
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, next has been updated
via a83bcf914c9214d522d99966386c0a989c651f0f (commit)
from 4f175a1f579e087949ddf6bd514082d40c0b7b44 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit a83bcf914c9214d522d99966386c0a989c651f0f
Author: Arne Fitzenreiter <arne_f(a)ipfire.org>
Date: Sat Jan 25 22:22:26 2020 +0100
networking/red: wait only for carrier if device exists
Signed-off-by: Arne Fitzenreiter <arne_f(a)ipfire.org>
-----------------------------------------------------------------------
Summary of changes:
src/initscripts/networking/red | 30 ++++++++++++++++--------------
1 file changed, 16 insertions(+), 14 deletions(-)
Difference in files:
diff --git a/src/initscripts/networking/red b/src/initscripts/networking/red
index 7ce0a6f47..b619836ae 100644
--- a/src/initscripts/networking/red
+++ b/src/initscripts/networking/red
@@ -129,21 +129,23 @@ case "${1}" in
ip route add default via ${GATEWAY} dev ${DEVICE}
evaluate_retval
- # has carrier ?
- if [ ! "$(</sys/class/net/${DEVICE}/carrier)" = "1" ]; then
- boot_mesg -n "Wait for carrier on ${DEVICE} "
- for (( i=30; i>1; i-- )) do
- if [ "$(</sys/class/net/${DEVICE}/carrier)" = "1" ]; then
- break;
- fi
- boot_mesg -n "."
- sleep 2
- done
- boot_mesg ""
+ if [ -d "/sys/class/net/${DEVICE}" ]; then
+ # has carrier ?
if [ ! "$(</sys/class/net/${DEVICE}/carrier)" = "1" ]; then
- echo_failure
- else
- echo_ok
+ boot_mesg -n "Wait for carrier on ${DEVICE} "
+ for (( i=30; i>1; i-- )) do
+ if [ "$(</sys/class/net/${DEVICE}/carrier)" = "1" ]; then
+ break;
+ fi
+ boot_mesg -n "."
+ sleep 2
+ done
+ boot_mesg ""
+ if [ ! "$(</sys/class/net/${DEVICE}/carrier)" = "1" ]; then
+ echo_failure
+ else
+ echo_ok
+ fi
fi
fi
hooks/post-receive
--
IPFire 2.x development tree
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-01-25 21:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-25 21:23 [git.ipfire.org] IPFire 2.x development tree branch, next, updated. a83bcf914c9214d522d99966386c0a989c651f0f Arne Fitzenreiter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox