🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.privacy.anon-server
Article #47012

The demise of Richard Heathfield (Was: Free reliable wordcount utility available (final version))

#47012
From: Thomas J. Boschloo
Date: Wed, 13 Nov 2002 18:09
71 lines
3768 bytes
Richard Heathfield wrote:
> 
> "Thomas J. Boschloo" wrote:
> >
> > Richard Heathfield wrote:
> > >
> > > "Thomas J. Boschloo" wrote:
> >
> > > > I just ran that version of my wordcnt utility on my 100mb
> > > > swapfile from MS-Dos. If finished well within a full hour :-)
> > > > That is a lot less then I expected at first. I ran out of
> > > > memory though.. 300000 words counted I believe, lot's of
> > > > MICROSOFT strings in my swapfile ;-P
> > >
> > > You'll be glad to know that you should be able to make it a lot
> > > faster. I just spent about half an hour writing a C++ version
> > > (C++ is considered by many, including me, to be slower than C),
> > > and it runs at a little over twice the speed of yours (on the
> > > same hardware, of course).
> > >
> > > If you want the source code, let me know.
> >
> > Yes I do.

> int GetWord(string &word, FILE *fp)
> {
>   int result = 0;
> 
>   int ch;
> 
>   word = "";
> 
>   /* skip leading spaces */
>   do
>   {
>     ch = fgetc(fp);
>   } while(ch != EOF && isspace((unsigned char)ch));
> 
>   if(ch != EOF)
>   {
>     do
>     {
>       word += ch;
>       ch = fgetc(fp);
>     } while(ch != EOF &&
>             (isalpha((unsigned char)ch) ||
>              '\'' == ch ||
>              '-' == ch));
>   }
> 
>   if(EOF == ch)
>   {
>     result = 1;
>   }
> 
>   return result;
> }

I think I see an unchecked buffer here, so I assume the whole post is a
nut post to paraphrase your own words.

I think we are done now unless you coded this program //REALLY// fast
and this single error slipped your mind. In any case, you still have to
find a similar flaw in my code AFAIK. Compilation errors do not put you
above the mental capabilities of an ANSI-C compiler AFAIK.

Goodbye, it has been a pleasure flaming you to a crisp,
Thomas
-- 
Mess with the best, die like the rest - Hackers
T.J. Boschloo <home.hccnet.nl/t.j.boschloo>
Technical Details
Message-ID: <3DD2955F.61C2149@hccnet.nl.invalid>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.security.pgp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!skynet.be!skynet.be!cleanfeed.casema.net!leda.casema.net!bnewspeer01.bru.ops.eu.uu.net!emea.uu.net!news.hccnet.nl!not-for-mail
References: <3DC1596C.6D2B55BD@hccnet.nl.invalid> <3DC526FC.CBCFE9B6@hccnet.nl.invalid> <3DC5451F.DBF3CDDA@eton.powernet.co.uk> <pan.2002.11.03.17.05.02.482162@yahoo.co.uk> <3DC81975.45915377@hccnet.nl.invalid> <3DC85EA2.2C8E26DA@earthlink.net> <3DC95533.512AB0A3@hccnet.nl.invalid> <3DC976DA.32815A18@earthlink.net> <3DCBC0A8.F3785708@hccnet.nl.invalid> <3DCC0E5A.4C70F9F@eton.powernet.co.uk> <3DCD229B.1F302611@hccnet.nl.invalid> <3DCD3356.EBE0DD11@eton.powernet.co.uk>

Show Full Headers
Complete Article Headers
Message-ID: <3DD2955F.61C2149@hccnet.nl.invalid>
Subject: The demise of Richard Heathfield (Was: Free reliable wordcount utility available (final version))
Date: Wed, 13 Nov 2002 19:09:35 +0100
From: "Thomas J. Boschloo" <nospam@hccnet.nl.invalid>
References: <3DC1596C.6D2B55BD@hccnet.nl.invalid> <3DC526FC.CBCFE9B6@hccnet.nl.invalid> <3DC5451F.DBF3CDDA@eton.powernet.co.uk> <pan.2002.11.03.17.05.02.482162@yahoo.co.uk> <3DC81975.45915377@hccnet.nl.invalid> <3DC85EA2.2C8E26DA@earthlink.net> <3DC95533.512AB0A3@hccnet.nl.invalid> <3DC976DA.32815A18@earthlink.net> <3DCBC0A8.F3785708@hccnet.nl.invalid> <3DCC0E5A.4C70F9F@eton.powernet.co.uk> <3DCD229B.1F302611@hccnet.nl.invalid> <3DCD3356.EBE0DD11@eton.powernet.co.uk>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.security.pgp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!skynet.be!skynet.be!cleanfeed.casema.net!leda.casema.net!bnewspeer01.bru.ops.eu.uu.net!emea.uu.net!news.hccnet.nl!not-for-mail
Newsgroups: alt.privacy.anon-server,sci.crypt,alt.fan.cult-dead-cow,alt.security.pgp
Organization: Hobby Computer Club News Network
Lines: 72
NNTP-Posting-Host: uds15-36.dial.hccnet.nl
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Trace: news.hccnet.nl 1037211200 11461 62.251.36.15 (13 Nov 2002 18:13:20 GMT)
X-Complaints-To: abuse@hccnet.nl
NNTP-Posting-Date: Wed, 13 Nov 2002 18:13:20 +0000 (UTC)
Cancel-Lock: sha1:QKE9mGUZcs63WPm1EuyId506ol8=
X-Mailer: Mozilla 4.8 [en] (Win98; U)
X-Accept-Language: en,nl,de
X-NFilter: 1.2.1-b1