Skip to content

Commit

Permalink
drivers/ieee1394/raw1394.c: fix a NULL pointer
Browse files Browse the repository at this point in the history
The coverity checker spotted that this was a NULL pointer dereference in
the "if (copy_from_user(...))" case since the next step is to
kfree(cache->filled_head).

There's no need to free cache at this point, and it's getting free'd
later.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Jody McIntyre <scjody@modernduck.com>
  • Loading branch information
Adrian Bunk authored and Jody McIntyre committed Nov 21, 2005
1 parent 977545e commit d734f92
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/ieee1394/raw1394.c
Original file line number Diff line number Diff line change
Expand Up @@ -2131,7 +2131,6 @@ static int modify_config_rom(struct file_info *fi, struct pending_request *req)
req->req.length)) {
csr1212_release_keyval(fi->csr1212_dirs[dr]);
fi->csr1212_dirs[dr] = NULL;
CSR1212_FREE(cache);
ret = -EFAULT;
} else {
cache->len = req->req.length;
Expand Down

0 comments on commit d734f92

Please sign in to comment.