From owner-freebsd-current Fri May 24 8:25:52 2002 Delivered-To: freebsd-current@freebsd.org Received: from anchor-post-30.mail.demon.net (anchor-post-30.mail.demon.net [194.217.242.88]) by hub.freebsd.org (Postfix) with ESMTP id 1398137B40A for ; Fri, 24 May 2002 08:25:48 -0700 (PDT) Received: from teabag.demon.co.uk ([193.237.4.110] helo=teabag.cbhnet) by anchor-post-30.mail.demon.net with esmtp (Exim 3.35 #1) id 17BGvr-000CXm-0U for freebsd-current@freebsd.org; Fri, 24 May 2002 16:24:43 +0100 Received: from localhost (localhost [127.0.0.1]) by teabag.cbhnet (Postfix) with ESMTP id D401465286 for ; Fri, 24 May 2002 16:24:04 +0100 (BST) Date: Fri, 24 May 2002 16:24:04 +0100 (BST) From: Chris Hedley X-X-Sender: cbh@teabag.cbhnet To: freebsd-current@freebsd.org Subject: Re: strtod & sscanf on -CURRENT? In-Reply-To: <20020524133357.GA15486@sysadm.stc> Message-ID: <20020524161853.U2404-100000@teabag.cbhnet> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 24 May 2002, Igor Roboul wrote: > Maybe I'm wrong, but I think that sscanf on -CURRENT does not work as > expected. Interestingly I had some aggro with both scanf and strtod returning somewhat random results recently (about 5th/6th May); I'm afraid I no longer have the results or test programs but I ended up having to hack my own routine together to get a reliable input. What I seem to recall is that scanf didn't return the correct result at all, whereas strtod was okay for the first couple of invocations within the same program, after which it began to return garbage (I'm pretty confident that my program didn't have a buffer overrun, it was a fairly short & simple effort) Chris. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message