Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754761AbYL0U2t (ORCPT ); Sat, 27 Dec 2008 15:28:49 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754044AbYL0U2h (ORCPT ); Sat, 27 Dec 2008 15:28:37 -0500 Received: from mail.parknet.ad.jp ([210.171.162.6]:46781 "EHLO mail.officemail.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753919AbYL0U2h (ORCPT ); Sat, 27 Dec 2008 15:28:37 -0500 From: OGAWA Hirofumi To: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Cc: hirofumi@mail.parknet.co.jp Subject: [PATCH] fat: drop negative dentry on rename() path Date: Sun, 28 Dec 2008 05:17:23 +0900 Message-Id: X-Mailer: git-send-email 1.6.0.5.dirty In-Reply-To: References: In-Reply-To: References: X-Anti-Virus: Kaspersky Anti-Virus for MailServers 5.5.10/RELEASE, bases: 24052007 #308098, status: clean Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1057 Lines: 32 Drop the negative dentry on rename() path, in order to make sure to use the case sensitive name which is specified by user if this is for creation. For it, this uses newly added LOOKUP_RENAME_TARGET like LOOKUP_CREATE. Signed-off-by: OGAWA Hirofumi --- fs/fat/namei_vfat.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/fs/fat/namei_vfat.c b/fs/fat/namei_vfat.c index bf326d4..8ae32e3 100644 --- a/fs/fat/namei_vfat.c +++ b/fs/fat/namei_vfat.c @@ -78,7 +78,7 @@ static int vfat_revalidate_ci(struct dentry *dentry, struct nameidata *nd) * for creation. */ if (!(nd->flags & (LOOKUP_CONTINUE | LOOKUP_PARENT))) { - if (nd->flags & LOOKUP_CREATE) + if (nd->flags & (LOOKUP_CREATE | LOOKUP_RENAME_TARGET)) return 0; } -- 1.6.0.5.dirty -- 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/