aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorHolger Freyther <zecke@openmoko.org>2008-11-19 17:09:45 +0000
committerAndy Green <agreen@pads.home.warmcat.com>2008-11-19 17:09:45 +0000
commitb8b1a156e9df097f6a0315e295a78270db1bd0f1 (patch)
tree7ebf5fec94e39bdd3ff6d8e59f08bd848e60195f /drivers
parent7f2ded2d5797cb9f0040e3596eb0fa01d6104921 (diff)
Fix possible null pointer dereference in s3c24xx_i2c_resume
From 0b9bae6aed5268707b348e48a01411ba420844e1 Mon Sep 17 00:00:00 2001 From: Holger Freyther <zecke@openmoko.org> Date: Tue, 27 May 2008 14:41:35 +0200 Subject: [PATCH] [janitor] Fix possible null pointer dereference Judging by the control flow of the resume method i2c->suspended++ could lead to a null pointer dereference.
Diffstat (limited to 'drivers')
-rw-r--r--drivers/i2c/busses/i2c-s3c2410.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c
index 3a86f23cf44..6a1cb34b6f7 100644
--- a/drivers/i2c/busses/i2c-s3c2410.c
+++ b/drivers/i2c/busses/i2c-s3c2410.c
@@ -991,8 +991,6 @@ static int s3c24xx_i2c_resume(struct platform_device *dev)
i2c->suspended = 0;
s3c24xx_i2c_init(i2c);
- i2c->suspended--;
-
return 0;
}