Messages in this thread |  | | Date | Fri, 1 Sep 2000 22:19:09 +0200 | From | Rasmus Andersen <> | Subject | Re: [patchlet] Removing unneeded line in vmtruncate() (2.4.0-t8p1) |
| |
On 0, Tigran Aivazian <tigran@veritas.com> wrote: > On Fri, 1 Sep 2000, Rasmus Andersen wrote: > > > Hi. > > > > AFAICS, the line removed below is redundant. Comments? > > > > --- linux-240test8-pre1/mm/memory.c Thu Aug 10 16:29:54 2000 > > +++ linux/mm/memory.c Fri Sep 1 22:00:16 2000 > > @@ -986,7 +986,6 @@ > > out_unlock: > > spin_unlock(&mapping->i_shared_lock); > > /* this should go into ->truncate */ > > - inode->i_size = offset; > > if (inode->i_op && inode->i_op->truncate) > > inode->i_op->truncate(inode); > > return; > > Rasmus, you introduced a bug because you removed the code but left the > comment around. now /* this should go into ->truncate */ is there and very > confusing - what should go into ->truncate?
Good point. So what is the Right Thing? Moving inode->i_size = offset into truncate() and cleaning up vmtruncate()? Or just kill the comment along with the other line? :)
I guess my kernel experience mostly lends itself to the latter, but I could take a shot at the former if it is the Right Thing.
Thanks for the prompt comment. -- Regards, Rasmus(rasmus@jaquet.dk)
Are they taking DDT? -- Vice President Dan Quayle asking doctors at a Manhattan AIDS clinic about their treatments of choice, 4/30/92 (reported in Esquire, 8/92, and NY Post early May 92) - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/
|  |