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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Received: by 2002:a5e:9505:: with SMTP id r5-v6mr21508818ioj.134.1537232014976; Mon, 17 Sep 2018 17:53:34 -0700 (PDT) X-Received: by 2002:aca:f5cc:: with SMTP id t195-v6mr1219oih.0.1537232014889; Mon, 17 Sep 2018 17:53:34 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.uzoreto.com!feeder.erje.net!2.eu.feeder.erje.net!newsreader4.netcologne.de!news.netcologne.de!peer03.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.am4!peer.am4.highwinds-media.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!x81-v6no24570ita.0!news-out.google.com!z5-v6ni32ite.0!nntp.google.com!x81-v6no24569ita.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Mon, 17 Sep 2018 17:53:34 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=121.45.194.120; posting-account=d51RWwoAAADvR-x0zYAtT9z3CRxT1eXo NNTP-Posting-Host: 121.45.194.120 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <5b291dba-a78b-4188-8658-f5fd3578ec54@googlegroups.com> Subject: Re: Interface To C Struct That Includes An Array From: Roger Injection-Date: Tue, 18 Sep 2018 00:53:34 +0000 Content-Type: text/plain; charset="UTF-8" X-Received-Bytes: 2392 X-Received-Body-CRC: 4152628205 Xref: reader02.eternal-september.org comp.lang.ada:54354 Date: 2018-09-17T17:53:34-07:00 List-Id: On Tuesday, September 18, 2018 at 2:29:20 AM UTC+10, Jeffrey R. Carter wrote: > On 09/17/2018 02:01 PM, rogermc@iinet.net.au wrote: > > > > (gdb) print Assimp_Path > > $8 = (length => 16, data => (0 => 11, 0, 0, 0, 112, 104, 111, 101, 110, 105, 120, 46, 112, 99, 120, 0 ) > > I have no idea what I'm talking about, so this may be totally useless, but the > 11 0 0 0 at the beginning looks like it might be some sort of encoding marker. > The first of the 1009 (or is it 1010?) zeros at the end is in position 16 (index > 15), so I presume it's the C string terminator. > > -- > Jeff Carter > "Oh Lord, bless this thy hand grenade, that with it thou > mayst blow thine enemies to tiny bits, in thy mercy." > Monty Python and the Holy Grail > 24 As I've explained to Lucretia, the 11 turns out to be an undisplayable ASCII character (either VT or DC1) which is displayed as a rectangular box containing four small zeros. So 11 0 0 0 is being interpreted as four chars rather than the expected size_t integer, I think.