Commit a11442fe authored by Christian Gromm's avatar Christian Gromm Committed by Greg Kroah-Hartman

Staging: most: fix passing a potential null pointer

This patch fixes passing of a potential null pointer.
Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarChristian Gromm <christian.gromm@microchip.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 2e4c3045
......@@ -204,7 +204,8 @@ static ssize_t aim_write(struct file *filp, const char __user *buf,
}
return actual_len - retval;
error:
most_put_mbo(mbo);
if (mbo)
most_put_mbo(mbo);
return err;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment