X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f X-Trace-PostClient-IP: 68.147.177.20 From: Brian Inglis Newsgroups: comp.os.msdos.djgpp Subject: Re: CTYPE stuff for Eli or DJ Organization: Systematic Software Message-ID: References: <200412241848 DOT iBOImiRM013524 AT envy DOT delorie DOT com> <200412241919 DOT iBOJJnq5014101 AT envy DOT delorie DOT com> <01c4ea6a$Blat.v2.2.2$88d35240 AT zahav DOT net DOT il> <200412251642 DOT iBPGge9n026679 AT envy DOT delorie DOT com> X-Newsreader: Forte Agent 1.93/32.576 English (American) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 19 Date: Sun, 26 Dec 2004 04:18:22 GMT NNTP-Posting-Host: 24.71.223.147 X-Complaints-To: abuse AT shaw DOT ca X-Trace: pd7tw1no 1104034702 24.71.223.147 (Sat, 25 Dec 2004 21:18:22 MST) NNTP-Posting-Date: Sat, 25 Dec 2004 21:18:22 MST To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com On Sat, 25 Dec 2004 14:54:54 -0500 in comp.os.msdos.djgpp, Joe Wright wrote: >There is no reference in the Standard about the >implementation segfaulting and what the user should do about it. The Standard requires the programmer to pass a valid unsigned char value or the special value EOF to all of the macros/functions defined in ctype.h. If you do not check your input you *will* get Undefined Behaviour! That may result in your program appearing to work correctly in the worst case, or causing a fault in the best case, as it indicates that you have done something wrong. -- Thanks. Take care, Brian Inglis Calgary, Alberta, Canada Brian DOT Inglis AT CSi DOT com (Brian[dot]Inglis{at}SystematicSW[dot]ab[dot]ca) fake address use address above to reply