linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Steve Dickson <SteveD@redhat.com>
To: Mi Jinlong <mijinlong@cn.fujitsu.com>
Cc: NFSv3 list <linux-nfs@vger.kernel.org>
Subject: Re: [PATCH] libnfs.a: fix a bug when parse section's arg
Date: Mon, 29 Nov 2010 11:06:45 -0500	[thread overview]
Message-ID: <4CF3CF95.7090506@RedHat.com> (raw)
In-Reply-To: <4CD36FE7.1010100@cn.fujitsu.com>



On 11/04/2010 10:45 PM, Mi Jinlong wrote:
> When parsing section's arg at configure file, the pointer 
> should stop when fetch ']', and give the warning message.
> 
> ---
>  support/nfs/conffile.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/support/nfs/conffile.c b/support/nfs/conffile.c
> index 24640f4..798e5f3 100644
> --- a/support/nfs/conffile.c
> +++ b/support/nfs/conffile.c
> @@ -271,9 +271,9 @@ conf_parse_line(int trans, char *line, size_t sz)
>  		if (ptr == NULL)
>  			return;
>  		line = ++ptr;
> -		while (*ptr && *ptr != '"')
> +		while (*ptr && *ptr != '"' && *ptr != ']')
>  			ptr++;
> -		if (*ptr == '\0') {
> +		if (*ptr == '\0' || *ptr == ']') {
>  			xlog_warn("config file error: line %d: "
>   				"non-matched '\"', ignoring until next section", ln);
>  		}  else {
Committed...

steved.

      parent reply	other threads:[~2010-11-29 16:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-05  2:45 [PATCH] libnfs.a: fix a bug when parse section's arg Mi Jinlong
2010-11-09  1:37 ` Mi Jinlong
2010-11-22 17:31   ` Steve Dickson
2010-11-24  9:07     ` Mi Jinlong
2010-11-29 16:06       ` Steve Dickson
2010-11-29 16:06 ` Steve Dickson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4CF3CF95.7090506@RedHat.com \
    --to=steved@redhat.com \
    --cc=linux-nfs@vger.kernel.org \
    --cc=mijinlong@cn.fujitsu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).