Re: [PATCH] 2.5.59: ftruncate/truncate oopses with mandatory locking

From: Robert Williamson (
Date: Thu Jan 23 2003 - 17:04:16 EST

>This patch fixes the truncate/ftruncate oopses with mandatory locking
>enabled. The problem with ftruncate is that the local variable fl is
>not initialized properly in locks_mandatory_area that it misbehaves at
>various places like locks_insert_block. And the problem with truncate
>is that the filp variable is NULL at posix_lock_file. The NULL value
>comes from do_sys_truncate.
locks_mandatory_area needed a bit more tweaking to allow correct error
handling, as well as
adherence to the O_NONBLOCK flag if/when used. Merged the original patch
with my updates,
 and updated the bug report.

>The bug report and details can be found at,

- Robbie

Robert V. Williamson <>
Linux Test Project
IBM Linux Technology Center
Phone: (512) 838-9295 T/L: 678-9295
Fax: (512) 838-4603
IRC: #ltp on
"Only two things are infinite, the universe and human stupidity, and I'm
not sure about the former." -Albert Einstein

(See attached file: bug280.patch)

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

This archive was generated by hypermail 2b29 : Thu Jan 23 2003 - 22:00:32 EST