From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id E0802A0679 for ; Wed, 3 Apr 2019 17:51:27 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 794761B4C5; Wed, 3 Apr 2019 17:51:27 +0200 (CEST) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 183C71B46D; Wed, 3 Apr 2019 17:51:21 +0200 (CEST) X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 03 Apr 2019 08:51:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,305,1549958400"; d="scan'208";a="146291970" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.7.174]) by FMSMGA003.fm.intel.com with SMTP; 03 Apr 2019 08:51:18 -0700 Received: by (sSMTP sendmail emulation); Wed, 03 Apr 2019 16:51:18 +0100 Date: Wed, 3 Apr 2019 16:51:17 +0100 From: Bruce Richardson To: Stephen Hemminger Cc: dev@dpdk.org, Declan Doherty , stable@dpdk.org Message-ID: <20190403155117.GA1332@bricha3-MOBL.ger.corp.intel.com> References: <20190403144505.46234-1-bruce.richardson@intel.com> <20190403144505.46234-2-bruce.richardson@intel.com> <20190403084758.2b7bed7f@shemminger-XPS-13-9360> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190403084758.2b7bed7f@shemminger-XPS-13-9360> User-Agent: Mutt/1.11.4 (2019-03-13) Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH 1/5] net/bonding: fix buffer length when printing strings X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" On Wed, Apr 03, 2019 at 08:47:58AM -0700, Stephen Hemminger wrote: > On Wed, 3 Apr 2019 15:45:01 +0100 > Bruce Richardson wrote: > > > > > static void > > -arp_op_name(uint16_t arp_op, char *buf) > > +arp_op_name(uint16_t arp_op, char *buf, size_t buf_len) > > { > > switch (arp_op) { > > case ARP_OP_REQUEST: > > - snprintf(buf, sizeof("ARP Request"), "%s", "ARP Request"); > > + snprintf(buf, buf_len, "%s", "ARP Request"); > > return; > This should be strlcpy not snprintf Yes, it should, but I just let that get fixed by cocci script in the later patch. For this one, I just fixed the most egregious error.