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 X-Google-Thread: 103376,23d2475711dc99b8 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-03-11 09:08:35 PST Path: archiver1.google.com!news2.google.com!news.maxwell.syr.edu!news.algonet.se!algonet!news-stoc.telia.net!217.209.241.210.MISMATCH!news-stod.telia.net!telia.net!masternews.telia.net.!newsc.telia.net.POSTED!not-for-mail From: =?ISO-8859-1?Q?Bj=F6rn_Persson?= User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.1) Gecko/20031114 X-Accept-Language: sv, en-us MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: A bug in Gnat, or in my code? References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Message-ID: Date: Thu, 11 Mar 2004 17:08:34 GMT NNTP-Posting-Host: 217.209.116.179 X-Complaints-To: abuse@telia.com X-Trace: newsc.telia.net 1079024914 217.209.116.179 (Thu, 11 Mar 2004 18:08:34 CET) NNTP-Posting-Date: Thu, 11 Mar 2004 18:08:34 CET Organization: Telia Internet Xref: archiver1.google.com comp.lang.ada:6245 Date: 2004-03-11T17:08:34+00:00 List-Id: Preben Randhol wrote: > I see. I think you have a bug in that you forgot to trim the text. No, that's intentional. There might be cases where the value must be=20 used as it is, with possible spaces. In fact, I just removed the Trim on = the name. I improved another part of the program and then the trimming=20 became unnecessary. > Anyhow I made a test of your program and ran it on gnat 3.3.3 from > Debian and it works there. No crash. So maybe it is only the packaging > of RedHat? A program shouldn't segmentation fault and this is typically= > an indication of a packaging/installation error. The Trim you inserted hides the bug, because Trim returns a more=20 conventional null string that doesn't cause problems in=20 To_Unbounded_String. After I removed it, your program crashes for me. Did you try my test program on that version of Gnat? --=20 Bj=F6rn Persson jor ers @sv ge. b n_p son eri nu