From: Erez Zadok Date: Tue, 6 Sep 2011 01:38:35 +0000 (-0400) Subject: Unionfs: force only one open lower file after copyup in open(2) X-Git-Url: https://git.fsl.cs.stonybrook.edu/?a=commitdiff_plain;h=1e2510afaa1369dc2767036958716ed30d2c1a68;p=unionfs-2.6.28.y.git Unionfs: force only one open lower file after copyup in open(2) Signed-off-by: Erez Zadok --- diff --git a/fs/unionfs/commonfops.c b/fs/unionfs/commonfops.c index 1301074407e..b154ccc95e1 100644 --- a/fs/unionfs/commonfops.c +++ b/fs/unionfs/commonfops.c @@ -505,8 +505,11 @@ static int __open_file(struct inode *inode, struct file *file, for (bindex = bstart - 1; bindex >= 0; bindex--) { err = copyup_file(parent->d_inode, file, bstart, bindex, size); - if (!err) + if (!err) { + /* only one regular file open */ + fbend(file) = fbstart(file); break; + } } return err; } else {