🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #2868

scanf %x allows leading 0x?!?

#2868
From: Larry Jones
Date: Thu, 09 May 1991 22:02
11 lines
946 bytes
I was just surprised to discover that the %x conversion specifier
used in the *scanf functions allows the target string to have a
leading 0x or 0X.  I don't remember any discussion about it and a
few quick tests show about a 50/50 split of systems that allow it
and systems that don't.  Was that behavior specified in the SVID
or /usr/group specs, was it picked up from somewhere else, or is
it just an unaticipated feature?
----
Larry Jones, SDRC, 2000 Eastman Dr., Milford, OH  45150-2789  513-576-2070
Domain: scjones@sdrc.com             Path: uunet!sdrc!scjones
Rats.  I can't tell my gum from my Silly Putty. -- Calvin
Technical Details
Message-ID: <161@thor.sdrc.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!uunet!sdrc!thor!scjones

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!uunet!sdrc!thor!scjones
From: scjones@thor.sdrc.com (Larry Jones)
Newsgroups: comp.std.c
Subject: scanf %x allows leading 0x?!?
Message-ID: <161@thor.sdrc.com>
Date: 9 May 91 22:02:36 GMT
Organization: SDRC, Cincinnati
Lines: 11