[PATCH] Fix NULL pointer dereference in isdn_tty_at_cout
[deliverable/linux.git] / drivers / isdn / i4l / isdn_tty.c
index f190a99604f0c3821c9e97e865819e4d89dfc144..393633681f49fa852ac549b2aeb48fc4d9ebf07d 100644 (file)
@@ -2359,8 +2359,8 @@ isdn_tty_at_cout(char *msg, modem_info * info)
 
        /* use queue instead of direct, if online and */
        /* data is in queue or buffer is full */
-       if ((info->online && tty_buffer_request_room(tty, l) < l) ||
-           (!skb_queue_empty(&dev->drv[info->isdn_driver]->rpqueue[info->isdn_channel]))) {
+       if (info->online && ((tty_buffer_request_room(tty, l) < l) ||
+           !skb_queue_empty(&dev->drv[info->isdn_driver]->rpqueue[info->isdn_channel]))) {
                skb = alloc_skb(l, GFP_ATOMIC);
                if (!skb) {
                        spin_unlock_irqrestore(&info->readlock, flags);
This page took 0.023463 seconds and 5 git commands to generate.