Quantcast
Channel: lkml.org : Shesha Sreenivasamurthy
Viewing all articles
Browse latest Browse all 1267

Re: Kernel crash in free_pipe_info()

$
0
0
Linus Torvalds writes: (Summary) We do
free_pipe_info(inode->i_pipe);
iput(inode);
iput(inode);
- we couldn't allocate any file at all:
- we couldn't allocate any file at all:
free_pipe_info(inode->i_pipe);
path_put(&path);
path_put(&path);
- we allocated the first file, but not the second:
- we allocated the first file, but not the second:
put_filp(f);
free_pipe_info(inode->i_pipe);
path_put(&path);
path_put(&path);
and it worries me a bit that in all those error cases, we end up doing that "free_pipe_info()", but we basically do this half-arsed job of freeing things.
freeing things.
For example, we use "put_filp()" to free the file pointer, not "fput()".

Viewing all articles
Browse latest Browse all 1267

Trending Articles