Messages in this thread Patch in this message | | | Date | Thu, 19 Apr 2007 17:34:11 +0300 (EEST) | From | Pekka J Enberg <> | Subject | [PATCH] revoke: only fput unused files |
| |
From: Pekka Enberg <penberg@cs.helsinki.fi>
We should do fput only to files that were not used by the revoke operation.
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi> --- fs/revoke.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
Index: uml-2.6/fs/revoke.c =================================================================== --- uml-2.6.orig/fs/revoke.c 2007-04-19 17:27:11.000000000 +0300 +++ uml-2.6/fs/revoke.c 2007-04-19 17:27:40.000000000 +0300 @@ -130,7 +130,6 @@ for (fd = 0; fd < fdt->max_fds; fd++) { } new_filp = revoke_table_get(table); - get_file(new_filp); /* * Replace original struct file pointer with a pointer to @@ -487,7 +486,7 @@ static void free_revoke_table(struct rev { int i; - for (i = 0; i < table->size; i++) + for (i = table->end; i < table->size; i++) fput(table->files[i]); kfree(table->files); - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |