socket call

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



I try to build a rtp DLL. The rtp_init() will call into udp_init4(), which
will call the folloiwng:
s->fd = socket(AF_INET, SOCK_DGRAM, 0);
But the s->fd returned back a negtive number. I linked wsock32.lib (from SDK
\lib for XP SP2) for the rtp project.
I am wondering what is going on? Is it because I did not init the socket?
Shold WSAStartup() solve the problem? But I was not allowed to include
winsock2.h.

Kevin c.
.



Relevant Pages

  • socket
    ... I try to build a rtp DLL. ... will call the folloiwng: ... Kevin c. ... Prev by Date: ...
    (microsoft.public.win32.programmer.networks)
  • Re: socket
    ... Arkady ... >I try to build a rtp DLL. ... > Kevin c. ... Prev by Date: ...
    (microsoft.public.win32.programmer.networks)
  • Re: socket call
    ... >I try to build a rtp DLL. ... > will call the folloiwng: ... Is it because I did not init the socket? ...
    (microsoft.public.win32.programmer.networks)