staging: dgnc: dgnc_tty: Remove useless initialisation
authorAmitoj Kaur Chawla <amitoj1606@gmail.com>
Thu, 15 Oct 2015 08:25:45 +0000 (13:55 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 17 Oct 2015 05:56:23 +0000 (22:56 -0700)
Remove intialisation of a variable that is immediately reassigned.

The semantic patch used to find this is:

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/dgnc/dgnc_tty.c

index 4ac9092da392a090dc7a34ee78a84c91951a0678..48e4b90578c17fdb037894d92348d065c4546544 100644 (file)
@@ -838,7 +838,7 @@ static void dgnc_set_custom_speed(struct channel_t *ch, uint newrate)
 
 void dgnc_check_queue_flow_control(struct channel_t *ch)
 {
-       int qleft = 0;
+       int qleft;
 
        /* Store how much space we have left in the queue */
        qleft = ch->ch_r_tail - ch->ch_r_head - 1;