Fix Oops when reporting 0 boards.
authorDavid Schleef <ds@schleef.org>
Thu, 5 Jul 2001 05:29:18 +0000 (05:29 +0000)
committerDavid Schleef <ds@schleef.org>
Thu, 5 Jul 2001 05:29:18 +0000 (05:29 +0000)
comedi/drivers/mite.c

index f72168ebf4bd005d5fc49a6e74b38fe293e22a37..c37461013a2793c06cb0e2d92cead1b7a7947815 100644 (file)
@@ -228,7 +228,7 @@ void mite_list_devices(void)
        struct mite_struct *mite,*next;
        
        printk("Available NI device IDs:");
-       for(mite=mite_devices;mite;mite=next){
+       if(mite_devices)for(mite=mite_devices;mite;mite=next){
                next=mite->next;
                printk(" 0x%04x",mite_device_id(mite));
                if(mite->used)printk("(used)");