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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,5355421156b0daa1 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-08-07 06:53:03 PST Path: archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!cpk-news-hub1.bbnplanet.com!washdc3-snh1.gtei.net!cambridge1-snf1.gtei.net!news.gtei.net!bos-service1.ext.raytheon.com!dfw-service2.ext.raytheon.com.POSTED!not-for-mail Message-ID: <3B6FF2BD.2D034487@raytheon.com> From: Mark Johnson Reply-To: mark_h_johnson@raytheon.com X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.4.2-2smp i686) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Data_Error - Where in this code? References: <1qstmt4hiaiutibe0jies4j0v04ll7mahs@4ax.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Tue, 07 Aug 2001 08:53:01 -0500 NNTP-Posting-Host: 192.27.48.41 X-Complaints-To: news@ext.ray.com X-Trace: dfw-service2.ext.raytheon.com 997192382 192.27.48.41 (Tue, 07 Aug 2001 08:53:02 CDT) NNTP-Posting-Date: Tue, 07 Aug 2001 08:53:02 CDT Organization: Raytheon Company Xref: archiver1.google.com comp.lang.ada:11495 Date: 2001-08-07T08:53:01-05:00 List-Id: Stewart wrote: > Hi, > > Help' > > The two procedures work seperately on Linux and jointly on Win98. > On linux I get the following data error using gnatmake. > > a-tiinio.adb:71 instantiated at latest.adb:9 > Hmm. Not on my system. I get the following messages from gnatmake.... $ gnatmake -g -k -f latest gcc -c -g latest.adb latest.adb:14:64: warning: "Max_Size" may be referenced before it has a value gnatbind -x latest.ali gnatlink -g latest.ali /usr/gnat/lib/gcc-lib/i686-pc-linux-gnu/2.8.1/adalib/libgnat.a(a-adaint.o): In function `__gnat_tmp_name': a-adaint.o(.text+0x504): the use of `tmpnam' is dangerous, better use `mkstemp' And if you try to run the program, STORAGE_ERROR is raised at line 14 because Max_Size is indeed referenced before it has a value. This is with gnat 3.15w (and I assume 3.14a1) as well. The error you refer to points to where DATA_ERROR is raised in the Ada run time. It would indicate that your input file doesn't have an integer at the point you are trying to read. You may wish to put in a little debug code to see what characters the program is trying to read when "get" is being called. [or alternatively, resend the program with a sample input file...] --Mark