ftp.delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
X-Received: | by 10.224.129.196 with SMTP id p4mr1722274qas.6.1372202820327; |
Tue, 25 Jun 2013 16:27:00 -0700 (PDT) | |
X-Received: | by 10.50.73.69 with SMTP id j5mr871310igv.14.1372202820289; Tue, |
25 Jun 2013 16:27:00 -0700 (PDT) | |
Newsgroups: | comp.os.msdos.djgpp |
Date: | Tue, 25 Jun 2013 16:26:59 -0700 (PDT) |
In-Reply-To: | <fa6e9d1a-62f9-42c9-a020-5c317d7c33da@googlegroups.com> |
Complaints-To: | groups-abuse AT google DOT com |
Injection-Info: | glegroupsg2000goo.googlegroups.com; posting-host=71.222.72.40; posting-account=jrLHRgkAAABPV01ZW_RN_U6Tm5UnYNUx |
NNTP-Posting-Host: | 71.222.72.40 |
References: | <36e857f0-9899-496b-9fc6-32251e109888 AT googlegroups DOT com> |
<kpo3gh$4qo$1 AT speranza DOT aioe DOT org> <858cbded-7989-46e6-a997-93f842cdb3b0 AT googlegroups DOT com> | |
<kq75ni$qvf$1 AT speranza DOT aioe DOT org> <020e0244-406c-4c1f-9dbc-d82a0fae976f AT googlegroups DOT com> | |
<fa6e9d1a-62f9-42c9-a020-5c317d7c33da AT googlegroups DOT com> | |
User-Agent: | G2/1.0 |
MIME-Version: | 1.0 |
Message-ID: | <efcd3df3-8410-4735-92c4-fee6c18e12fc@googlegroups.com> |
Subject: | Re: General Protection Fault error is intermittent |
From: | "K.J.Williams" <lordwilliams1972 AT gmail DOT com> |
Injection-Date: | Tue, 25 Jun 2013 23:27:00 +0000 |
Bytes: | 2980 |
Lines: | 55 |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id r5PNj2KA015453 |
Reply-To: | djgpp AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | djgpp AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
On Tuesday, June 25, 2013 8:45:35 AM UTC-7, rug DOT DOT DOT AT gmail DOT com wrote: > Hi, > > > > On Tuesday, June 25, 2013 3:24:59 AM UTC-5, K.J.Williams wrote: > > > > > > BTW, I found another bug with DJGPP > > > > > > if you have program that just uses : > > > > > > #include<stdio.h> > > > #include<string.h> > > > > > > ...and you use a function from ctype.h - as I did with isspace(), > > > without including ctype.h in your includes ... DJGPP/GCC will NOT > > > complain about it and will still compile it. > > > > Originally, way way back, C didn't have a preprocessor at all. I > > think, without explicit prototypes, C assumes every function returns > > an int. C nowadays only has simple file inclusion, thus it's not true > > modules, hence instead of the compiler checking for consistency, it's > > left to the linker to resolve. But for varargs functions (e.g. printf) > > you always have to include the header for prototype as it's allowed > > to change the ABI. > Well I have noticed this in some .h files (which I can read in RHIDE), they sometimes #include other .h(s) before the defintions. I thought , maybe string.h or stdio.h has a ctype.h included which is allowing me to get away from actually using #include<ctype.h> in my code that I was needing isspace(); for. But I immediately added that #include to my source code to prevent future problems
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |