tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

wsdisplay_kbdholdscreen()



Hi,

I just had a "drop to DDB due to null-pointer de-reference" event
with a 4.0.1 installation, which occurred under unclear
circumstances, but "random" keyboard input is not ruled out.

By the looks of it, this patch would have prevented the problem:

Index: wsdisplay.c
===================================================================
RCS file: /u/nb/src/sys/dev/wscons/wsdisplay.c,v
retrieving revision 1.122
diff -u -p -r1.122 wsdisplay.c
--- wsdisplay.c 12 Jun 2008 23:04:37 -0000      1.122
+++ wsdisplay.c 7 Nov 2008 12:19:39 -0000
@@ -2067,6 +2067,9 @@ wsdisplay_kbdholdscreen(device_t dv, int
 
        scr = sc->sc_focus;
 
+       if (!scr)
+               return;
+
        if (hold)
                scr->scr_hold_screen = 1;
        else {

Does anyone know of a good reason I should not commit this, and
ask for pull-ups?

Regards,

- Håvard


Home | Main Index | Thread Index | Old Index