[PATCH] xfree86: Add option parsing for percent options.
Keith Packard
keithp at keithp.com
Thu May 13 04:19:55 PDT 2010
On Thu, 13 May 2010 16:07:44 +1000, Peter Hutterer <peter.hutterer at who-t.net> wrote:
> + if (sscanf(s, "%ld%1[%]", &p->value.num, tmp) != 2) {
Could you use
char tmp;
sscanf(s, "%ld%c", &p->value.num, &tmp)
and then check tmp to see if it was '%'?
--
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20100513/d3a653b5/attachment.pgp>
More information about the xorg-devel
mailing list