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-Thread: a07f3367d7,865c3d125a8dbc3b X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!postnews.google.com!o30g2000vbc.googlegroups.com!not-for-mail From: andrew Newsgroups: comp.lang.ada Subject: Re: Howto read line from a stream Date: Thu, 4 Jun 2009 07:16:10 -0700 (PDT) Organization: http://groups.google.com Message-ID: <58aa2239-2983-4c5e-877b-0836477a73a2@o30g2000vbc.googlegroups.com> References: <83317a97-dae5-4c84-a1ac-88a87833cf3f@q14g2000vbn.googlegroups.com> <1a90e055-44a3-4d00-b4cd-64798c731a55@e24g2000vbe.googlegroups.com> <709e8a12-f967-43db-b76b-4852cf1db08b@v4g2000vba.googlegroups.com> NNTP-Posting-Host: 139.78.128.110 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: posting.google.com 1244124970 18059 127.0.0.1 (4 Jun 2009 14:16:10 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 4 Jun 2009 14:16:10 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: o30g2000vbc.googlegroups.com; posting-host=139.78.128.110; posting-account=nEabzAoAAACAOfb_WmFJ5X5xOdAgoaUs User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; InfoPath.2; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:6245 Date: 2009-06-04T07:16:10-07:00 List-Id: Just a random thought here: If the read a Character, increase size of buffer, append the Character, free old buffer cycle is "a problem" then why not read a byte and write (append) it to a file? Then, when there is no more data to read you could read the entire line from the file in one call. Again, just a thought. Andrew