Browse Source

Input: edt-ft5x06 - remove redundant null check before kfree

kfree on a null pointer is a no-op. Hence null check is not
necessary.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Sachin Kamat 12 years ago
parent
commit
8efcc50323
1 changed files with 1 additions and 2 deletions
  1. 1 2
      drivers/input/touchscreen/edt-ft5x06.c

+ 1 - 2
drivers/input/touchscreen/edt-ft5x06.c

@@ -440,8 +440,7 @@ static int edt_ft5x06_work_mode(struct edt_ft5x06_ts_data *tsdata)
 		return -EIO;
 	}
 
-	if (tsdata->raw_buffer)
-		kfree(tsdata->raw_buffer);
+	kfree(tsdata->raw_buffer);
 	tsdata->raw_buffer = NULL;
 
 	/* restore parameters */