Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/14563/?format=api
http://patches.dpdk.org/api/patches/14563/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/1467718979-20904-1-git-send-email-jianfeng.tan@intel.com/", "project": { "id": 1, "url": "http://patches.dpdk.org/api/projects/1/?format=api", "name": "DPDK", "link_name": "dpdk", "list_id": "dev.dpdk.org", "list_email": "dev@dpdk.org", "web_url": "http://core.dpdk.org", "scm_url": "git://dpdk.org/dpdk", "webscm_url": "http://git.dpdk.org/dpdk", "list_archive_url": "https://inbox.dpdk.org/dev", "list_archive_url_format": "https://inbox.dpdk.org/dev/{}", "commit_url_format": "" }, "msgid": "<1467718979-20904-1-git-send-email-jianfeng.tan@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/1467718979-20904-1-git-send-email-jianfeng.tan@intel.com", "date": "2016-07-05T11:42:59", "name": "[dpdk-dev] net/virtio: fix null pointer dereference", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "234766369ffda3b2faf317d21b4a8cb4239b6275", "submitter": { "id": 313, "url": "http://patches.dpdk.org/api/people/313/?format=api", "name": "Jianfeng Tan", "email": "jianfeng.tan@intel.com" }, "delegate": { "id": 355, "url": "http://patches.dpdk.org/api/users/355/?format=api", "username": "yliu", "first_name": "Yuanhan", "last_name": "Liu", "email": "yuanhan.liu@linux.intel.com" }, "mbox": "http://patches.dpdk.org/project/dpdk/patch/1467718979-20904-1-git-send-email-jianfeng.tan@intel.com/mbox/", "series": [], "comments": "http://patches.dpdk.org/api/patches/14563/comments/", "check": "pending", "checks": "http://patches.dpdk.org/api/patches/14563/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<dev-bounces@dpdk.org>", "X-Original-To": "patchwork@dpdk.org", "Delivered-To": "patchwork@dpdk.org", "Received": [ "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id 98D15568D;\n\tTue, 5 Jul 2016 13:43:23 +0200 (CEST)", "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n\tby dpdk.org (Postfix) with ESMTP id 68C9D5680\n\tfor <dev@dpdk.org>; Tue, 5 Jul 2016 13:43:22 +0200 (CEST)", "from orsmga001.jf.intel.com ([10.7.209.18])\n\tby fmsmga104.fm.intel.com with ESMTP; 05 Jul 2016 04:43:22 -0700", "from dpdk06.sh.intel.com ([10.239.128.225])\n\tby orsmga001.jf.intel.com with ESMTP; 05 Jul 2016 04:43:18 -0700" ], "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.26,579,1459839600\"; d=\"scan'208\";a=\"989407200\"", "From": "Jianfeng Tan <jianfeng.tan@intel.com>", "To": "dev@dpdk.org", "Cc": "yuanhan.liu@linux.intel.com, huawei.xie@intel.com,\n\tmichalx.k.jastrzebski@intel.com, Jianfeng Tan <jianfeng.tan@intel.com>", "Date": "Tue, 5 Jul 2016 11:42:59 +0000", "Message-Id": "<1467718979-20904-1-git-send-email-jianfeng.tan@intel.com>", "X-Mailer": "git-send-email 2.1.4", "Subject": "[dpdk-dev] [PATCH] net/virtio: fix null pointer dereference", "X-BeenThere": "dev@dpdk.org", "X-Mailman-Version": "2.1.15", "Precedence": "list", "List-Id": "patches and discussions about DPDK <dev.dpdk.org>", "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>", "List-Archive": "<http://dpdk.org/ml/archives/dev/>", "List-Post": "<mailto:dev@dpdk.org>", "List-Help": "<mailto:dev-request@dpdk.org?subject=help>", "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>", "Errors-To": "dev-bounces@dpdk.org", "Sender": "\"dev\" <dev-bounces@dpdk.org>" }, "content": "There is a logic bug in this code, that could lead to null pointer\ndereference when cvq is NULL. Fix this problem by changing logic\n_and_ to logic _or_.\n\n >> CID 127480: Null pointer dereferences (FORWARD_NULL)\n >> Dereferencing null pointer \"cvq\".\n \tif (!cvq && !cvq->vq) {\n ...\n }\n\nCoverity issue: 127480\n\nFixes: 01ad44fd374f (\"net/virtio: split Rx/Tx queue\")\n\nSigned-off-by: Jianfeng Tan <jianfeng.tan@intel.com>\n---\n drivers/net/virtio/virtio_ethdev.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)", "diff": "diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c\nindex 480daa3..828afef 100644\n--- a/drivers/net/virtio/virtio_ethdev.c\n+++ b/drivers/net/virtio/virtio_ethdev.c\n@@ -166,7 +166,7 @@ virtio_send_command(struct virtnet_ctl *cvq, struct virtio_pmd_ctrl *ctrl,\n \n \tctrl->status = status;\n \n-\tif (!cvq && !cvq->vq) {\n+\tif (!cvq || !cvq->vq) {\n \t\tPMD_INIT_LOG(ERR, \"Control queue is not supported.\");\n \t\treturn -1;\n \t}\n", "prefixes": [ "dpdk-dev" ] }{ "id": 14563, "url": "