From nobody Sun Nov 2 00:43:23 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1508520006102861.2561636183189; Fri, 20 Oct 2017 10:20:06 -0700 (PDT) Received: from localhost ([::1]:55029 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e5axi-0004qq-C2 for importer@patchew.org; Fri, 20 Oct 2017 13:19:58 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39025) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e5avY-0003gz-Qm for qemu-devel@nongnu.org; Fri, 20 Oct 2017 13:17:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e5avV-0004qo-Dt for qemu-devel@nongnu.org; Fri, 20 Oct 2017 13:17:44 -0400 Received: from 7.mo5.mail-out.ovh.net ([178.32.124.100]:36177) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1e5avV-0004q2-7a for qemu-devel@nongnu.org; Fri, 20 Oct 2017 13:17:41 -0400 Received: from player773.ha.ovh.net (b9.ovh.net [213.186.33.59]) by mo5.mail-out.ovh.net (Postfix) with ESMTP id E72A2147080 for ; Fri, 20 Oct 2017 19:17:39 +0200 (CEST) Received: from bahia.lan (gar31-1-82-66-74-139.fbx.proxad.net [82.66.74.139]) (Authenticated sender: groug@kaod.org) by player773.ha.ovh.net (Postfix) with ESMTPA id BEEC5600076; Fri, 20 Oct 2017 19:17:38 +0200 (CEST) From: Greg Kurz To: qemu-devel@nongnu.org Date: Fri, 20 Oct 2017 19:17:38 +0200 Message-ID: <150851985854.6309.16575977719112120440.stgit@bahia.lan> User-Agent: StGit/0.17.1-46-g6855-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Ovh-Tracer-Id: 3437090942256912704 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedttddrvddtgdduuddvucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecufedttdenuc X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 178.32.124.100 Subject: [Qemu-devel] [PATCH] 9pfs: fix v9fs_mark_fids_unreclaim() return value X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Greg Kurz Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 The return value of v9fs_mark_fids_unreclaim() is then propagated to pdu_complete(). It should be a negative errno, not -1. Signed-off-by: Greg Kurz Reviewed-by: Eric Blake --- hw/9pfs/9p.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c index f8bbac251dc9..52d46632fe15 100644 --- a/hw/9pfs/9p.c +++ b/hw/9pfs/9p.c @@ -512,7 +512,7 @@ static int coroutine_fn v9fs_mark_fids_unreclaim(V9fsPD= U *pdu, V9fsPath *path) /* reopen the file/dir if already closed */ err =3D v9fs_reopen_fid(pdu, fidp); if (err < 0) { - return -1; + return err; } /* * Go back to head of fid list because