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,62ab88cac7a1dbb X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.180.106.102 with SMTP id gt6mr577852wib.0.1348233624076; Fri, 21 Sep 2012 06:20:24 -0700 (PDT) Path: q11ni9090952wiw.1!nntp.google.com!feeder2.cambriumusenet.nl!feed.tweaknews.nl!193.141.40.65.MISMATCH!npeer.de.kpn-eurorings.net!npeer-ng0.de.kpn-eurorings.net!border2.nntp.ams2.giganews.com!border4.nntp.ams.giganews.com!border2.nntp.ams.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!newsfeed.news.ucla.edu!news.snarked.org!weretis.net!feeder4.news.weretis.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: Gnat Sockets & Streams Date: Sat, 15 Sep 2012 08:28:22 +0100 Organization: A noiseless patient Spider Message-ID: References: <201209142101005065-rblove@airmailnet> Mime-Version: 1.0 Injection-Info: mx04.eternal-september.org; posting-host="a9272c9c584810f74e3f95ce46cbeceb"; logging-data="1137"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/vVMCIvq85iC9nk22/Z0ye0aqnmBZ0LvE=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (darwin) Cancel-Lock: sha1:no31HRmB8nK1n6HDTy0qfrKso5A= sha1:ITNM/fm5gGLVJ2fwvBHZWzGRoLo= Content-Type: text/plain Date: 2012-09-15T08:28:22+01:00 List-Id: Robert Love writes: > I've a problem with the Gnat.Sockets that is driving me crazy. I have > to use multicast to announce a service is available. > When I insert this code into my actual program it works differently. > The string comes over 1 character at at time. I've looked over the > code to see that I used the package exactly like the example. I've > had coworkers look it over. We don't see any way the > > String'Output(Channel, "Dummy Data"); > > can output the data one character at a time. The Output is in a > loop and I would expect to see > > Dummy Data > Dummy Data > Dummy Data > > instead of > > D > u > m > m > y > > D > > by the receiving program. I've also used tcpdump to see that the > packet really contains just one character instead of there being a > problem with the receiving progam. > > Is there any way a stream can be corrupted? Any settings parameters > I could compile with that change the behavior? That is, I believe, the behaviour specified by the ARM[1], paras 25..27 and 9. This happened to me a long time ago, I thought AdaCore had implemented an optimisation for strings. You could try writing a new String and overriding 'Write (shouldn't need to override 'Output, but maybe ...) [1] http://www.ada-auth.org/standards/12rm/html/RM-13-13-2.html