From patchwork Fri Oct 11 20:15:54 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Geyslan G. Bem" X-Patchwork-Id: 3027781 Return-Path: X-Original-To: patchwork-linux-nfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 2712FBF924 for ; Fri, 11 Oct 2013 20:22:31 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6103420278 for ; Fri, 11 Oct 2013 20:22:30 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9C5232026F for ; Fri, 11 Oct 2013 20:22:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932595Ab3JKUWI (ORCPT ); Fri, 11 Oct 2013 16:22:08 -0400 Received: from mail-yh0-f50.google.com ([209.85.213.50]:33587 "EHLO mail-yh0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932190Ab3JKUWH (ORCPT ); Fri, 11 Oct 2013 16:22:07 -0400 Received: by mail-yh0-f50.google.com with SMTP id b6so904768yha.23 for ; Fri, 11 Oct 2013 13:22:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=FhAMHMAGNtMZiLRFv2a9hFhpGJSyxZqSNS4PpyNyfHU=; b=xaoTZX92WtkVKEOddxa7Qo+MYvsDX+UOu6Iny2yEGRtSBfLhKGcfOjpZm7rjxnApm8 VmI20X0HT//5u1J1eg2VFJRYnzRKjx49ZHzkUPK5x6byxdzt8trzlLGsUGmJgTwNzXtc VCI2BeFt0A1K4HaPVE1Hh1hAzhEy1CfJJ/rSBvTZpOjLBVHbt6v14AC7CRyDzOy1DNrt g+s53kAZ/LVTjX1JbT302D62nfiTaLAG4ZOFD9kUWlfIhOWge3GF/ju9COkzwtF2CjF6 dAJtCnTNSM4PYwci4G1B/51z6Ju5QzsXtFK2B34uwKTShdq0pZpLWOdfyDtkrbt+/3J5 Sqow== X-Received: by 10.236.27.196 with SMTP id e44mr13645743yha.16.1381522925965; Fri, 11 Oct 2013 13:22:05 -0700 (PDT) Received: from localhost.localdomain (179-197-250-50.user.veloxzone.com.br. [179.197.250.50]) by mx.google.com with ESMTPSA id v96sm81285297yhp.3.1969.12.31.16.00.00 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Oct 2013 13:22:05 -0700 (PDT) From: "Geyslan G. Bem" To: Trond.Myklebust@netapp.com Cc: linux-nfs@vger.kernel.org, linux-kernel@vger.kernel.org, joe@perches.com, kernel-br@googlegroups.com, "Geyslan G. Bem" Subject: [PATCH] nfs: Remove useless 'error' assignment Date: Fri, 11 Oct 2013 17:15:54 -0300 Message-Id: <1381522554-22243-1-git-send-email-geyslan@gmail.com> X-Mailer: git-send-email 1.8.4 Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Spam-Status: No, score=-7.0 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP the 'error' variable was been assigned twice in vain. Signed-off-by: Geyslan G. Bem --- fs/nfs/unlink.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/nfs/unlink.c b/fs/nfs/unlink.c index bb939ed..0c29b1b 100644 --- a/fs/nfs/unlink.c +++ b/fs/nfs/unlink.c @@ -493,7 +493,7 @@ nfs_sillyrename(struct inode *dir, struct dentry *dentry) unsigned long long fileid; struct dentry *sdentry; struct rpc_task *task; - int error = -EIO; + int error = -EBUSY; dfprintk(VFS, "NFS: silly-rename(%s/%s, ct=%d)\n", dentry->d_parent->d_name.name, dentry->d_name.name, @@ -503,7 +503,6 @@ nfs_sillyrename(struct inode *dir, struct dentry *dentry) /* * We don't allow a dentry to be silly-renamed twice. */ - error = -EBUSY; if (dentry->d_flags & DCACHE_NFSFS_RENAMED) goto out;