From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Ahern Subject: Re: [iproute PATCH v5 3/5] Replace malloc && memset by calloc Date: Mon, 18 Jul 2016 10:10:09 -0600 Message-ID: References: <1468853325-9260-1-git-send-email-phil@nwl.cc> <1468853325-9260-4-git-send-email-phil@nwl.cc> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: Daniel Borkmann , Nicolas Dichtel , Julien Floret , David Laight , netdev@vger.kernel.org To: Phil Sutter , Stephen Hemminger Return-path: Received: from mail-io0-f173.google.com ([209.85.223.173]:33360 "EHLO mail-io0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751590AbcGRQKN (ORCPT ); Mon, 18 Jul 2016 12:10:13 -0400 Received: by mail-io0-f173.google.com with SMTP id 38so163922867iol.0 for ; Mon, 18 Jul 2016 09:10:13 -0700 (PDT) In-Reply-To: <1468853325-9260-4-git-send-email-phil@nwl.cc> Sender: netdev-owner@vger.kernel.org List-ID: On 7/18/16 8:48 AM, Phil Sutter wrote: > This only replaces occurrences where the newly allocated memory is > cleared completely afterwards, as in other cases it is a theoretical > performance hit although code would be cleaner this way. > > Signed-off-by: Phil Sutter > --- > Changes since v2: > - Fix checkpatch errors. > --- > genl/genl.c | 3 +-- > lib/names.c | 7 ++----- > misc/lnstat.c | 6 ++---- > misc/lnstat_util.c | 4 +--- > tc/em_canid.c | 4 ++-- > tc/m_action.c | 3 +-- > tc/m_ipt.c | 13 ++++--------- > tc/m_pedit.c | 3 +-- > tc/tc.c | 9 +++------ > tc/tc_bpf.c | 4 +--- > tc/tc_class.c | 3 +-- > tc/tc_exec.c | 3 +-- > 12 files changed, 20 insertions(+), 42 deletions(-) Acked-by: David Ahern