Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752682AbaG2CkS (ORCPT ); Mon, 28 Jul 2014 22:40:18 -0400 Received: from mail-pa0-f50.google.com ([209.85.220.50]:35007 "EHLO mail-pa0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751779AbaG2CkQ (ORCPT ); Mon, 28 Jul 2014 22:40:16 -0400 Date: Mon, 28 Jul 2014 08:39:35 -0700 From: Stephen Hemminger To: Rickard Strandqvist Cc: Jeff Kirsher , Jesse Brandeburg , Bruce Allan , Carolyn Wyborny , Don Skidmore , Greg Rose , Alex Duyck , John Ronciak , Mitch Williams , Linux NICS , e1000-devel@lists.sourceforge.net, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: ethernet: intel: ixgbe: ixgbe_main.c: Cleaning up missing null-terminate in conjunction with strncpy Message-ID: <20140728083935.6f4b77c1@samsung-9> In-Reply-To: <1406384676-2606-1-git-send-email-rickard_strandqvist@spectrumdigital.se> References: <1406384676-2606-1-git-send-email-rickard_strandqvist@spectrumdigital.se> X-Mailer: Claws Mail 3.10.1 (GTK+ 2.24.24; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 26 Jul 2014 16:24:36 +0200 Rickard Strandqvist wrote: > Replacing strncpy with strlcpy to avoid strings that lacks null terminate. > > Signed-off-by: Rickard Strandqvist > --- hw->mac.type, hw->phy.type, hw->phy.sfp_type, This patch doesn't change anything. Netdev is already zeroed when allocated therefore doing strncpy() guarantees it will be null terminated. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/