diff --git a/usr.sbin/ppp/bundle.c b/usr.sbin/ppp/bundle.c index 1769b9f36916..c2e659e09575 100644 --- a/usr.sbin/ppp/bundle.c +++ b/usr.sbin/ppp/bundle.c @@ -721,11 +721,10 @@ bundle_Create(const char *prefix, int type, int unit) } } #endif - err = errno; - break; - } else if (errno == ENOENT) { - if (++enoentcount > 2) + if (errno != ENOENT || ++enoentcount > 2) { + err = errno; break; + } } else err = errno; }