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-Google-Thread: 103376,1f2bb9a889c13dc8,start X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.74.201 with SMTP id w9mr22307822pbv.0.1325079157125; Wed, 28 Dec 2011 05:32:37 -0800 (PST) Path: lh20ni73826pbb.0!nntp.google.com!news2.google.com!postnews.google.com!u32g2000yqe.googlegroups.com!not-for-mail From: Ada BRL Newsgroups: comp.lang.ada Subject: Characters stream through Network Sockets (C <=> Ada) Date: Wed, 28 Dec 2011 05:32:36 -0800 (PST) Organization: http://groups.google.com Message-ID: <0ca20824-422d-4384-8486-67301c35e5c6@u32g2000yqe.googlegroups.com> NNTP-Posting-Host: 93.62.202.2 Mime-Version: 1.0 X-Trace: posting.google.com 1325079156 15243 127.0.0.1 (28 Dec 2011 13:32:36 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Wed, 28 Dec 2011 13:32:36 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: u32g2000yqe.googlegroups.com; posting-host=93.62.202.2; posting-account=yig7mwoAAAAAcduNbH7Dpal1sjCSAijA User-Agent: G2/1.0 X-Google-Web-Client: true X-Google-Header-Order: HNKUARELSC X-HTTP-UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.7 (KHTML, like Gecko) Chrome/16.0.912.63 Safari/535.7,gzip(gfe) Content-Type: text/plain; charset=ISO-8859-1 Date: 2011-12-28T05:32:36-08:00 List-Id: Hello everyone! This is my problem: I have a C program that sends/receives data to/from an Ada program through Network sockets (pkg GNAT.Sockets). I can send a string from the Ada program to the C program. BUT I can't send any string (or array of chars) from the C program to the Ada one: the only thing that works is sending only one character at a time. I've tried using 'Read and 'Input member functions of several types (Chars, String, Interfaces.C.char_array, ...) but nothing worked. The funniest thing is that inside the C program the send function seems to be working, since it returns the correct number of characters sent. Instead, the Ada program blocks itself on 'Read (or 'Input) function and freezes. Do anyone know how to read a char stream coming from a C program? (I'm using Winsock2 legacy library) Thank you very very much!!!!