-# $OpenBSD: rc,v 1.551 2021/07/22 18:09:04 sthen Exp $
+# $OpenBSD: rc,v 1.552 2021/07/22 18:29:47 deraadt Exp $
# System startup script run by init on autoboot or after single-user.
# Output and error are redirected to console by init, and the console is the
reorder_libs
-# Pause a little so at least one dynamic (slaacd or dhcpleased) config completes
-count=0
-while ((count++ < 20)); do
- route -n show | grep -q ^default && break
- sleep .5
-done
+# If interface autoconf exists, pause a little for at least one default route
+if ifconfig | grep -q ': flags=.*<.*AUTOCONF.*> mtu'; then
+ count=0
+ while ((count++ < 20)); do
+ route -n show | grep -q ^default && break
+ sleep .5
+ done
+fi
# Load pf rules and bring up pfsync interface.
if [[ $pf != NO ]]; then