diff options
author | scottl <scottl@FreeBSD.org> | 2005-04-29 04:47:11 +0000 |
---|---|---|
committer | scottl <scottl@FreeBSD.org> | 2005-04-29 04:47:11 +0000 |
commit | 6a5362b1bc0a27a8d84ea5ffa3cb421d0cd72d2b (patch) | |
tree | 27093600d8ea690a113b1c61a17090d9960919c9 /sys | |
parent | 40dc0ad0703ccca4e61a6a731ed284dd1c18bf61 (diff) | |
download | FreeBSD-src-6a5362b1bc0a27a8d84ea5ffa3cb421d0cd72d2b.zip FreeBSD-src-6a5362b1bc0a27a8d84ea5ffa3cb421d0cd72d2b.tar.gz |
Only create the rdpti alias if the asr device creation succeeds.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/asr/asr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/asr/asr.c b/sys/dev/asr/asr.c index a6dff07..56a9462 100644 --- a/sys/dev/asr/asr.c +++ b/sys/dev/asr/asr.c @@ -2582,7 +2582,8 @@ asr_attach(device_t tag) */ sc->ha_devt = make_dev(&asr_cdevsw, unit, UID_ROOT, GID_OPERATOR, 0640, "asr%d", unit); - (void)make_dev_alias(sc->ha_devt, "rdpti%d", unit); + if (sc->ha_devt != NULL) + (void)make_dev_alias(sc->ha_devt, "rdpti%d", unit); sc->ha_devt->si_drv1 = sc; return(0); } /* asr_attach */ |