[Qt-interest] Alternative for bind() in TCP sockets

sarvesh saran aquarian.thunder at gmail.com
Tue Jan 25 06:48:56 CET 2011


Hi Anisha,

Can you show a snippet of your code ( the connections, the read call etc) ?
That will really help people in answering your questions..

thanks,
Sarvesh

On Tue, Jan 25, 2011 at 11:05 AM, Anisha Kaul <
anisha.kaul at hitechroboticsystemz.com> wrote:

> I have made the server listen in the constructor and wrote a connect
> call for the next pending connection (which return 1)
>
> >From another connect call (which also returns 1) I have called a
> function which is supposed to read the incoming data on server.
> In the read() I have passed a char array as the first arg and 2 as
> second args (i.e. number of bytes to be read)
>
> Now the problem is the read() returns -1, which should have instead
> returned 0, if there were no data!
>
> any idea where I am going wrong?
>
> -Anisha
>
>
>
>
> -------------------------------------
> Hi-Tech Gears Limited, Gurgaon, India
>
>
>
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110125/d5279425/attachment.html 


More information about the Qt-interest-old mailing list