linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Roman Zippel <zippel@linux-m68k.org>
To: Andrew Morton <akpm@osdl.org>, linux-fsdevel@vger.kernel.org
Subject: [PATCH 1/6] update key after rename
Date: Thu, 21 Oct 2004 01:12:43 +0200 (CEST)	[thread overview]
Message-ID: <Pine.LNX.4.61.0410210112070.1063@scrub.home> (raw)


After a file has been renamed, the cached search key must be updated.

Signed-off-by: Roman Zippel <zippel@linux-m68k.org>

Index: linux-2.6/fs/hfs/dir.c
===================================================================
--- linux-2.6.orig/fs/hfs/dir.c	2004-03-11 21:43:41.000000000 +0100
+++ linux-2.6/fs/hfs/dir.c	2004-10-01 20:47:42.000000000 +0200
@@ -306,6 +306,9 @@ int hfs_rename(struct inode *old_dir, st
 	res = hfs_cat_move(old_dentry->d_inode->i_ino,
 			   old_dir, &old_dentry->d_name,
 			   new_dir, &new_dentry->d_name);
+	if (!res)
+		hfs_cat_build_key((btree_key *)&HFS_I(old_dentry->d_inode)->cat_key,
+				  new_dir->i_ino, &new_dentry->d_name);
 	return res;
 }
 

                 reply	other threads:[~2004-10-20 23:12 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.61.0410210112070.1063@scrub.home \
    --to=zippel@linux-m68k.org \
    --cc=akpm@osdl.org \
    --cc=linux-fsdevel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).