From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1014db,582dff0b3f065a52 X-Google-Attributes: gid1014db,public X-Google-Thread: 109fba,582dff0b3f065a52 X-Google-Attributes: gid109fba,public X-Google-Thread: 103376,bc1361a952ec75ca X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-08-07 16:24:54 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!canoe.uoregon.edu!arclight.uoregon.edu!wn4feed!worldnet.att.net!135.173.83.71!wnfilter1!worldnet-localpost!bgtnsc04-news.ops.worldnet.att.net.POSTED!not-for-mail Message-ID: <3B70795F.DDF8A2AC@worldnet.att.net> From: James Rogers X-Mailer: Mozilla 4.76 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++ Subject: Re: How Ada could have prevented the Red Code distributed denial of service attack. References: <3b690498.1111845720@news.worldonline.nl> <9kbu15$9bj@augusta.math.psu.edu> <3b6a453c.1193942215@news.worldonline.nl> <9keejl$fhj@augusta.math.psu.edu> <3c30da40.0108060848.796d9bd9@posting.google.com> <3B6F3216.F410BBFF@home.com> <3B6F3FAE.B9B9FFCF@globetrotter.qc.ca> <3B6F5BB2.A879B933@worldnet.att.net> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Tue, 07 Aug 2001 23:24:54 GMT NNTP-Posting-Host: 12.74.161.245 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc04-news.ops.worldnet.att.net 997226694 12.74.161.245 (Tue, 07 Aug 2001 23:24:54 GMT) NNTP-Posting-Date: Tue, 07 Aug 2001 23:24:54 GMT Organization: AT&T Worldnet Xref: archiver1.google.com comp.lang.ada:11552 comp.lang.c:72779 comp.lang.c++:80808 Date: 2001-08-07T23:24:54+00:00 List-Id: Kaz Kylheku wrote: > > In article <3B6F5BB2.A879B933@worldnet.att.net>, James Rogers wrote: > > generic > > > > Max_Size : Positive; > > type Items is private; > > > > package Inventory is > > > > subtype Buf_Index is Positive range 1..Max_Size; > > type Parts_Buffer is array(Buf_Index) of Items; > > By the way, is there a reason why you didn't just use a modulo > type as the array index, one that will automatically wrap around > 1..Max_Size-1? No. Just simple foolishness. I simply got out of the habit of starting my counting with 0. Jim Rogers Colorado Springs, Colorado USA