Prevent module unloading if there are active connections.

PR:		kern/89085
Submitted by:	Rostislav Krasny
MFC after:	1 week
This commit is contained in:
Boris Popov 2005-11-22 02:15:46 +00:00
parent ba3612cd5c
commit 19caf6c088

View File

@ -346,7 +346,8 @@ nsmb_dev_load(module_t mod, int cmd, void *arg)
case MOD_UNLOAD:
smb_iod_done();
error = smb_sm_done();
error = 0;
if (error)
break;
EVENTHANDLER_DEREGISTER(dev_clone, nsmb_dev_tag);
printf("netsmb_dev: unloaded\n");
break;