[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20090925104203.GA11323@c.hsd1.tn.comcast.net>
Date: Fri, 25 Sep 2009 10:42:03 +0000
From: Andy Spencer <andy753421@...il.com>
To: "Am??rico Wang" <xiyou.wangcong@...il.com>
Cc: linux-kernel@...r.kernel.org
Subject: Re: [PATCH] fix %*s%n in sscanf
> > int end;
> > char buf[] = "hello world";
> > sscanf(buf, "%*s%n", &end);
> > printf("%d\n", end);
>
> Yeah, seems reasonable. So, without your patch, sscanf() in kernel
> will ignore everything after '*', right?
Currently it ignores everything between '*' and whitespace. So '%*s%n'
does not work, but '%*s %n' will correctly return the start of "world".
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists