[patch] staging: speakup: fix async usb removal

2017-08-12 Thread Okash Khawaja
When an external USB synth is unplugged while the module is loaded, we get a null pointer deref. This is because the tty disappears while speakup tries to use to to communicate with the synth. This patch fixes it by checking tty for null before using it. Since tty can become null between the check

[patch] staging: speakup: fix async usb removal

2017-08-12 Thread Okash Khawaja
When an external USB synth is unplugged while the module is loaded, we get a null pointer deref. This is because the tty disappears while speakup tries to use to to communicate with the synth. This patch fixes it by checking tty for null before using it. Since tty can become null between the check