From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id DC6BBA0540; Wed, 15 Jul 2020 08:33:00 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8EF511C0AD; Wed, 15 Jul 2020 08:32:59 +0200 (CEST) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id 30F671C07D for ; Wed, 15 Jul 2020 08:32:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1594794777; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=CQ3vyqfCbiaFnpaSYDRPw6VrN4CGItQ6CFE+YWE47kc=; b=ITmaiK+Jz60Ac/16Y1N92vOKDe/GbZS5k7aVitLPVj3c8TP4r72oe6qhCD46SrIUHnvmKc KMpvjTt4FV8ERzu6dWdQBizmiCXBzj4yDIqOX1KczeW5AL5kjdT9WiLRdNwH6QQa5MkmPE TxQOCv3tn/Z8qbmxzbHeUsGpdbSzIko= Received: from mail-wr1-f72.google.com (mail-wr1-f72.google.com [209.85.221.72]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-417-wXGNCj83O7-JxK_-hG_mFw-1; Wed, 15 Jul 2020 02:32:55 -0400 X-MC-Unique: wXGNCj83O7-JxK_-hG_mFw-1 Received: by mail-wr1-f72.google.com with SMTP id y13so437744wrp.13 for ; Tue, 14 Jul 2020 23:32:54 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:autocrypt :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=CQ3vyqfCbiaFnpaSYDRPw6VrN4CGItQ6CFE+YWE47kc=; b=CRblH106cmtD5zIfUa28OAF0zyiWYpI90+FY1q1CDdgCTNXNp/Q8ZfiW7j5vcSIU50 EQP4Cd9sSB9DYTADa0GafNIpPnnAQf6P2LTmDrKmi0z/hriHCM4ZvGltGLFrVvEMAa9e +R+MZgwfNY8SgjRYHRKId0QtGXiyg7IyacxUj46Lm3EKUOEDK7Hfi/17QM0EQ4Bnvbna Zo0zNLC6u5Qrhl8/VEVN37+xXH6SY3luTUAjsdU2Dzbtb4d3vUjC739yILAEyOosrlbl VIGqLDmQzHiDErw0Aev38+YuFevvxFPclNi/h5AzjVFEezwnXlsdTTMz4d5dGMzvKA9U SWeA== X-Gm-Message-State: AOAM53016R8sracTLhTmFKymN3TLOAozXta6+QjtIH5z9M5XxwHQ9gmx 5NHAYJdIp88+zUl4t+ZNTLdazuUqatzm1jyY22aHJSDkn0ZjmoG9Etn48mQkNdbe7UrVCHrSeAV iXDw= X-Received: by 2002:a7b:cbcb:: with SMTP id n11mr6700980wmi.99.1594794774102; Tue, 14 Jul 2020 23:32:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0V8SgBYVNbxkp8GPASLf/rJHwK72rb0lLQgRg49NpqD+apZK1Y427aGZJljmEQukUYhaF3Q== X-Received: by 2002:a7b:cbcb:: with SMTP id n11mr6700967wmi.99.1594794773908; Tue, 14 Jul 2020 23:32:53 -0700 (PDT) Received: from amorenoz.users.ipa.redhat.com ([92.176.159.3]) by smtp.gmail.com with ESMTPSA id d13sm1841397wrq.89.2020.07.14.23.32.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 14 Jul 2020 23:32:53 -0700 (PDT) To: Chenbo Xia , dev@dpdk.org Cc: maxime.coquelin@redhat.com, zhihong.wang@intel.com References: <20200714110305.73911-1-chenbo.xia@intel.com> From: Adrian Moreno Autocrypt: addr=amorenoz@redhat.com; prefer-encr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IMDC4ZWrPsskjEy1YN/U10 r6tRRH1kNyrCSbTG0d9MtcQO58h7DLXuzUhErB+BtG52A04t5cweIJTJC+koV5XPeilzlHnm RFoj0ncruGa9Odns21BNt3cy9wLfK+aUnWuAB1uc6bJGQPiAwjkilz7g7MBRUuIQ2Zt7HGLc SwARAQABiQE8BBgBCAAmFiEEogUDgihhmbOPHy26d5C5fbYeFsUFAl1syNUCGwwFCQHhM4AA CgkQd5C5fbYeFsUlSwf8CH+u/IXaE7WeWxwFkMaORfW8cM4q0xrL3M6yRGuQNW+kMjnrvK9U J9G+L1/5uTRbDQ/4LdoKqize8LjehA+iF6ba4t9Npikh8fLKWgaJfQ/hPhH4C3O5gWPOLTW6 ylGxiuER4CdFwQIoAMMslhFA7G+teeOKBq36E+1+zrybI6Xy1UBSlpDK9j4CtTnMQejjuSQb Qhle+l8VroaUHq869wjAhRHHhqmtJKggI+OvzgQpDIwfHIDypb1BuKydi2W6cVYEALUYyCLS dTBDhzj8zR5tPCsga8J7+TclQzkWOiI2C6ZtiWrMsL/Uym3uXk5nsoc7lSj7yLd/MrBRhYfP JQ== Message-ID: Date: Wed, 15 Jul 2020 08:32:52 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: <20200714110305.73911-1-chenbo.xia@intel.com> Content-Language: en-US X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [PATCH v1] net/virtio-user: fix uninitialized variable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 7/14/20 1:03 PM, Chenbo Xia wrote: > This patch fixes an issue that uninitialized has_reply_ack > is used for setting message flags. > > Coverity issue: 360834 > Fixes: c60208dd6384 ("net/virtio-user: support reply-ack") > > Signed-off-by: Chenbo Xia > --- > drivers/net/virtio/virtio_user/vhost_user.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/virtio/virtio_user/vhost_user.c b/drivers/net/virtio/virtio_user/vhost_user.c > index 631d0e353..ad48bafd4 100644 > --- a/drivers/net/virtio/virtio_user/vhost_user.c > +++ b/drivers/net/virtio/virtio_user/vhost_user.c > @@ -254,7 +254,7 @@ vhost_user_sock(struct virtio_user_dev *dev, > struct vhost_user_msg msg; > struct vhost_vring_file *file = 0; > int need_reply = 0; > - int has_reply_ack; > + int has_reply_ack = 0; > int fds[VHOST_MEMORY_MAX_NREGIONS]; > int fd_num = 0; > int len; > Acked-by: Adrián Moreno -- Adrián Moreno