From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [v3 2/3] LPM config file read option. Date: Mon, 6 Mar 2017 08:46:19 -0800 Message-ID: <20170306084620.5bb094b5@xeon-e3> References: <1488660259-6228-1-git-send-email-rkerur@gmail.com> <1488660259-6228-3-git-send-email-rkerur@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, konstantin.ananyev@intel.com, bruce.richardson@intel.com To: Ravi Kerur Return-path: Received: from mail-pf0-f174.google.com (mail-pf0-f174.google.com [209.85.192.174]) by dpdk.org (Postfix) with ESMTP id 7AC08FA43 for ; Mon, 6 Mar 2017 17:46:22 +0100 (CET) Received: by mail-pf0-f174.google.com with SMTP id w189so62532732pfb.0 for ; Mon, 06 Mar 2017 08:46:22 -0800 (PST) In-Reply-To: <1488660259-6228-3-git-send-email-rkerur@gmail.com> 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 Sat, 4 Mar 2017 12:44:18 -0800 Ravi Kerur wrote: > +/* Bypass comment and empty lines */ > +static inline int > +is_bypass_line(char *buff) > +{ > + int i = 0; > + > + /* comment line */ > + if (buff[0] == COMMENT_LEAD_CHAR) > + return 1; > + /* empty line */ > + while (buff[i] != '\0') { > + if (!isspace(buff[i])) > + return 0; > + i++; > + } > + return 1; > +} This is not performance crtitical should not be inline. The argument is never modified and therefore should be "const char *buff"