summaryrefslogtreecommitdiff
path: root/drivers/staging/most
diff options
context:
space:
mode:
authorShivani Bhardwaj <shivanib134@gmail.com>2015-10-15 16:12:01 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-10-16 23:08:39 -0700
commitbba76322c3075776f222c4c7dd36f954ed458250 (patch)
tree5c6029f05bc7ef3d2712ff0d9ec6cf1c86abc6a7 /drivers/staging/most
parentb981da12513469324a18ae8250bca2848f8bf787 (diff)
Staging: most: cdev: Remove useless check
The variable mbo is already NULL tested so, check on it should be removed. Semantic patch used: @@ expression E; statement S; @@ if(E==NULL) {... return ...;} - if(E) S Signed-off-by: Shivani Bhardwaj <shivanib134@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/most')
-rw-r--r--drivers/staging/most/aim-cdev/cdev.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/most/aim-cdev/cdev.c b/drivers/staging/most/aim-cdev/cdev.c
index 16be88e2b454..212a667820df 100644
--- a/drivers/staging/most/aim-cdev/cdev.c
+++ b/drivers/staging/most/aim-cdev/cdev.c
@@ -208,8 +208,7 @@ static ssize_t aim_write(struct file *filp, const char __user *buf,
}
return actual_len - retval;
error:
- if (mbo)
- most_put_mbo(mbo);
+ most_put_mbo(mbo);
return err;
}