Message ID | 20171215174225.31583-17-ebiggers3@gmail.com |
---|---|
State | Deferred |
Delegated to: | Richard Weinberger |
Headers | show
Return-Path: <linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=65.50.211.133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="CYgjvHUV"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="Rocz0EHb"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="Qnx65BE9"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yyygY3RDWz9ryk for <incoming@patchwork.ozlabs.org>; Sat, 16 Dec 2017 04:52:25 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=U9Vl+oV+Dfhmz2vlohbU3oW7BGzjVfIDVsO1HxfrJcQ=; b=CYgjvHUVZlU6ztXKTm/B/QNP7c uqEFuNAart8VBczCnsqwUxE89W/GapF1HHt5AC4qacP6YC8R7b9wmh5Poj03lQmRBiWnLlAOwVdhv +apCZ735ZpPkHcQOzg3BLGU3KsH8F2c/5LnCsrMi9Mw2+a32Bse9WAZWOuzCGU46lbMJU/LiEUOMy tW6TA0Tr7v++ePRTNtYVHjbziYEqd7KNBYFLh4hZ4jXnxaHSs5AfgUBbi91xx3MqJw0bj5fF1Lx0I 6oK4shikPV4lLVtZBAZKiMN0ysu6DsAIF2ROenoQPj6dw1qRwh95VgQHR67nBIxkrRliMMuH4pbur 4IgRWldA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1ePu9Q-0004iv-Mu; Fri, 15 Dec 2017 17:52:00 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1ePu4w-0000As-7O for linux-mtd@bombadil.infradead.org; Fri, 15 Dec 2017 17:47:23 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=aFarVJDJje9P8A6brStU+9Fg/KwsmO+5Nm4yG0QfpvQ=; b=Rocz0EHb5fB0IBpUKdryfKiOS tLn/pvAjH5yBQiYmto11XpF7Es+93MLfccXzKoXIJNDQEITHHNjU31PhKHQxYtRi5m0Ui73Ln4uyk 4G+FbuLTOVNdlEq4XQg/ppt6hSUpAbzWF7VhDQ4TRMMiQ1+k3/hvlw3JdHB2NLm1Alu7FnTDR6N8e xvjd+98xT4frq5ZmUQ3FgB5idYjN1yryhr0qEmrJcdGg0u0VFGf7UsK5pQqLwx8Tp/7MwwMsqukP1 62cX+vL3SFTznKiIE3ngoul07NaRG5pkMw727Heb2U8O+YcbR2n8pr/InG+YRp1PCgOWB92EpM7l9 YDubknN5g==; Received: from mail-pg0-x244.google.com ([2607:f8b0:400e:c05::244]) by casper.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1ePu4r-0004lQ-2w for linux-mtd@lists.infradead.org; Fri, 15 Dec 2017 17:47:19 +0000 Received: by mail-pg0-x244.google.com with SMTP id g7so6264467pgs.0 for <linux-mtd@lists.infradead.org>; Fri, 15 Dec 2017 09:46:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=aFarVJDJje9P8A6brStU+9Fg/KwsmO+5Nm4yG0QfpvQ=; b=Qnx65BE9fByLvULF64eIvsLom8UqNM/DUIEPiBZjrILvjW7AUnTudNA44d334IWzUY x+7S0Fqd3Lz7iZj9Cmel61RdqMjKOyh1iS2JiO+ADZUKmVC5P1FULD6VSoRv2bzt6sLU EBD/dRIoXlAsUzopnBNUV+9g0tc3+4UOkXYSZxCWwRgNjRDeXwYZtUoxduFtQyVVWMXO YaDAFQtoyAsYvBUqw08PFtl5fFFnwJKVTtwMzcT5rtx4wo3IbnV5nn1Qe8PhO6MY/wD/ 4roj0/ym77qgqm4EbBYqn08YKObJfmscF4Ni3Qx1LAPHQu3sYFZPOQXquGUvJPaStVFl 7fvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=aFarVJDJje9P8A6brStU+9Fg/KwsmO+5Nm4yG0QfpvQ=; b=O3J5jSk/m0htwdGxUqOWm+mVF8zB3/aitujfJTKFzIK0k7B4pejPsy9cFD+LVlPTDE wKS3xwfkzxqSdupB1BlOsoddpqCYmBi8eggNKtk4nPYXutoPpxyDzgoT72A9ftS0umOS eZCVIqlSba2BDIstZI+6dSaVNLc6zbMgMweRNa7sAYXf3nm4hErLfhwknM49xzNfvAob kI4vJi0KAYxXS+jKr3jc8lLin8lrwbEt4CoBikDdekiuk6V/xb67luESroBdBRTyn5H4 7/LDbokf6WGXKSfq0X5fL/v6mRMk6BH1MRVJjc9J5uZf/nhJ8e2mefKrdfmv+vcdVSEy XI+g== X-Gm-Message-State: AKGB3mL18r5zckeZ/wVnRj04yKtP5SI3BIIbvS5X7uLFWanRGmO+W4gv YYJtjGe7vPN3xjvdmifo3j8= X-Google-Smtp-Source: ACJfBosskEJuXW1XE433vZGiMyTmm2VATGIrW3cDXhJjDgLU/xmZKbAKNd2Ks1sM8uxBHMDvF7/xPA== X-Received: by 10.159.230.11 with SMTP id u11mr13977330plq.185.1513360015450; Fri, 15 Dec 2017 09:46:55 -0800 (PST) Received: from zzz.localdomain (c-67-185-97-198.hsd1.wa.comcast.net. [67.185.97.198]) by smtp.gmail.com with ESMTPSA id j62sm12980149pfc.18.2017.12.15.09.46.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 15 Dec 2017 09:46:54 -0800 (PST) From: Eric Biggers <ebiggers3@gmail.com> To: linux-fscrypt@vger.kernel.org Subject: [PATCH 16/24] ubifs: free the encrypted symlink target Date: Fri, 15 Dec 2017 09:42:17 -0800 Message-Id: <20171215174225.31583-17-ebiggers3@gmail.com> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20171215174225.31583-1-ebiggers3@gmail.com> References: <20171215174225.31583-1-ebiggers3@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171215_174717_327289_EBC20050 X-CRM114-Status: GOOD ( 11.41 ) X-Spam-Score: -1.8 (-) X-Spam-Report: SpamAssassin version 3.4.1 on casper.infradead.org summary: Content analysis details: (-1.8 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [2607:f8b0:400e:c05:0:0:0:244 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (ebiggers3[at]gmail.com) 0.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends in digit (ebiggers3[at]gmail.com) -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux MTD discussion mailing list <linux-mtd.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-mtd>, <mailto:linux-mtd-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-mtd/> List-Post: <mailto:linux-mtd@lists.infradead.org> List-Help: <mailto:linux-mtd-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-mtd>, <mailto:linux-mtd-request@lists.infradead.org?subject=subscribe> Cc: "Theodore Y . Ts'o" <tytso@mit.edu>, Eric Biggers <ebiggers@google.com>, stable@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, linux-mtd@lists.infradead.org, Jaegeuk Kim <jaegeuk@kernel.org>, linux-ext4@vger.kernel.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-mtd" <linux-mtd-bounces@lists.infradead.org> Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org |
Series |
fscrypt: symlink helpers and fscrypt.h cleanup
|
expand
|
diff --git a/fs/ubifs/dir.c b/fs/ubifs/dir.c index 417fe0b29f23..ef820f803176 100644 --- a/fs/ubifs/dir.c +++ b/fs/ubifs/dir.c @@ -1216,10 +1216,8 @@ static int ubifs_symlink(struct inode *dir, struct dentry *dentry, ostr.len = disk_link.len; err = fscrypt_fname_usr_to_disk(inode, &istr, &ostr); - if (err) { - kfree(sd); + if (err) goto out_inode; - } sd->len = cpu_to_le16(ostr.len); disk_link.name = (char *)sd; @@ -1251,11 +1249,10 @@ static int ubifs_symlink(struct inode *dir, struct dentry *dentry, goto out_cancel; mutex_unlock(&dir_ui->ui_mutex); - ubifs_release_budget(c, &req); insert_inode_hash(inode); d_instantiate(dentry, inode); - fscrypt_free_filename(&nm); - return 0; + err = 0; + goto out_fname; out_cancel: dir->i_size -= sz_change; @@ -1268,6 +1265,7 @@ static int ubifs_symlink(struct inode *dir, struct dentry *dentry, fscrypt_free_filename(&nm); out_budg: ubifs_release_budget(c, &req); + kfree(sd); return err; }