Unplugging usb wireless card causes linux to hang
I have a usb wireless lan card that works with ndiswrapper perfectly but when I unplug it, the system freezes. This happens in all dists of linux.
Of course, in some dists, if I issue the command: "modprobe -r ndiswrapper" before unplugging the card, the system doesn't hang.
So my question is that because I found the command above arbitrary, I don't know if it is the best solution. Do you know better one? or do you know a way which itself unload modules in unplugging time automatically so that the system doesn't hang?