delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2003/08/29/13:43:17

Date: Fri, 29 Aug 2003 19:42:57 +0200 (CEST)
Message-Id: <200308291742.h7THgvTw005443@speedy.ludd.luth.se>
From: Martin Str|mberg <ams AT ludd DOT luth DOT se>
To: djgpp-workers AT delorie DOT com
Subject: (fwd) Re: sscanf's return value
X-MailScanner: Found to be clean
Reply-To: djgpp-workers AT delorie DOT com

I posted the following and still no comment. I think they agree
(silence is golden). The previous articles made their option
clear. Anyone not thinking so, please follow-up the article or one of
its siblings in the newsgroup. Hence we do have a bug in *scanf(). (No
I'm not volunteering to correct it.)


Right,

						MartinS

-- forwarded message --
Path: news.luth.se!luth.se!not-for-mail
Message-ID: <3f3e233f$0$170$cc7c7865 AT news DOT luth DOT se>
From: Martin Str|mberg <ams AT speedy DOT ludd DOT luth DOT se>
Subject: Re: sscanf's return value
Newsgroups: comp.std.c
References: <bgatrp$r0u$5 AT sunnews DOT cern DOT ch> <3f29164b DOT 214278 AT news DOT siemens DOT at>     <Pine DOT LNX DOT 4 DOT 55L-032 DOT 0307311425590 DOT 8512 AT unix48 DOT andrew DOT cmu DOT edu> <bgbsd2$7ch$1 AT news DOT tuwien DOT ac DOT at> <Pine DOT LNX DOT 4 DOT 55L-032 DOT 0307312225220 DOT 25522 AT unix46 DOT andrew DOT cmu DOT edu> <bgli0a$qi8$2 AT sunnews DOT cern DOT ch> <3f33e413$0$165$cc7c7865 AT news DOT luth DOT se> <3F341372 DOT 4112ED56 AT null DOT net> <3f342e20$0$165$cc7c7865 AT news DOT luth DOT se> <Il6dnVHc09h2E6miXTWJjg AT comcast DOT com> <3f34b197$0$167$cc7c7865 AT news DOT luth DOT se> <b_adnbwIdvrjD6iiXTWJjg AT comcast DOT com>
Organization: 
User-Agent: tin/1.4.6-20020816 ("Aerials") (UNIX) (NetBSD/1.6Q (alpha))
Date: 16 Aug 2003 12:27:43 GMT
Lines: 18
NNTP-Posting-Host: speedy.ludd.luth.se
X-Trace: 1061036863 news.luth.se 170 130.240.16.13
Xref: news.luth.se comp.std.c:14071

Let's see if I got this now.

``sscanf("", "%*[0123456789]%*c");'' should return EOF (input
failure).

``sscanf("X", "%*[0123456789]%*c");'' should return 0 as there's not
an input failure but a matching failure.

``sscanf("1", "%*[0123456789]%*c");'' should return EOF as there's a
input failure after matching ``1''.

``sscanf("1X2", "%*[0123456789]%*[0123456789]"'' should return 0 as
there's a matching failure after matching ``1''.


Right?

						MartinS
-- end of forwarded message --

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019