From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933241AbbHJVaH (ORCPT ); Mon, 10 Aug 2015 17:30:07 -0400 Received: from aserp1040.oracle.com ([141.146.126.69]:50974 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932726AbbHJVaF (ORCPT ); Mon, 10 Aug 2015 17:30:05 -0400 Date: Tue, 11 Aug 2015 00:29:55 +0300 From: Dan Carpenter To: Jan Kara Cc: linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] quota: remove an unneeded condition Message-ID: <20150810212955.GA31724@mwanda> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.23 (2014-03-12) X-Source-IP: userv0021.oracle.com [156.151.31.71] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We know "ret" is zero here so we can remove this condition. Signed-off-by: Dan Carpenter diff --git a/fs/quota/quota.c b/fs/quota/quota.c index 86ded73..3746367 100644 --- a/fs/quota/quota.c +++ b/fs/quota/quota.c @@ -141,9 +141,9 @@ static int quota_getinfo(struct super_block *sb, int type, void __user *addr) if (tstate->flags & QCI_ROOT_SQUASH) uinfo.dqi_flags |= DQF_ROOT_SQUASH; uinfo.dqi_valid = IIF_ALL; - if (!ret && copy_to_user(addr, &uinfo, sizeof(uinfo))) + if (copy_to_user(addr, &uinfo, sizeof(uinfo))) return -EFAULT; - return ret; + return 0; } static int quota_setinfo(struct super_block *sb, int type, void __user *addr)