[PATCH] I2C hwmon: kfree fixes
[linux-2.6.git] / drivers / hwmon / adm1031.c
index 4211c8b..9362509 100644 (file)
@@ -845,7 +845,7 @@ static int adm1031_detach_client(struct i2c_client *client)
        if ((ret = i2c_detach_client(client)) != 0) {
                return ret;
        }
-       kfree(client);
+       kfree(i2c_get_clientdata(client));
        return 0;
 }