From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Rybchenko Subject: Re: [PATCH] bus/pci: correct the earlier strlcpy conversion Date: Tue, 15 May 2018 13:51:10 +0300 Message-ID: <369bf5db-ad87-73cb-3470-901fe243c4a2@solarflare.com> References: <2DBBFF226F7CF64BAFCA79B681719D953A44992E@SHSMSX101.ccr.corp.intel.com> <152636946035.95095.1840276672620244597.stgit@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Cc: To: Andy Green , Return-path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id 78B771B989 for ; Tue, 15 May 2018 12:51:20 +0200 (CEST) In-Reply-To: <152636946035.95095.1840276672620244597.stgit@localhost.localdomain> Content-Language: en-GB 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 05/15/2018 10:31 AM, Andy Green wrote: > Fixes: fe5f777b5383 ("bus/pci: replace strncpy by strlcpy") > Signed-off-by: Andy Green Reviewed-by: Andrew Rybchenko Suggest to reword it as: bus/pci: fix invalid size of driver name buffer Variable dri_name is a pointer and it is incorrect to use its size as the buffer size. Caller knows the buffer size and it is safer to pass it explicitly.