Re: WSAEADDRNOTAVAIL how to resolve

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Omar [MS] (omarm_at_online.microsoft.com)
Date: 09/28/04


Date: Tue, 28 Sep 2004 15:39:13 -0700

Are you binding to a specific port? If so try changing the port does it
work. You can also specify the port to be 0 in which case the stack will
choose a free port for you.

If the above step fails or you're already binding to 0, try binding to
address 0 (techinically INADDR_ANY), again the stack will pick an
appropriate interface for you. After doing binding to ip address INADDR_ANY,
and port 0, assuming you succeed you can get the address that it bound to
and make sure that it was the same one you were trying.

Another common mistake is that you may be using the address with the bytes
in the wrong order try binding with net_long(ipaddr).

Thanks,
- Omar

-- 
This posting is provided "AS IS" with no warranties, and confers no rights.
Please do not send
email directly to this alias.  This alias is for newsgroup purposes only.
"cg" <cg@discussions.microsoft.com> wrote in message
news:952A28A8-B9AD-42B0-8621-8BE24405E589@microsoft.com...
> I am creating UDP socket with AF_INET, SOCK_DGRAM, IPPROTO_UDP options.
> When I do bind I get error WSAEADDRNOTAVAIL.  The documentation on window
CE
> states specifying an IP address in bind that does not correspond to a
local
> IP interface will generate this error. The local IP address is correct.
>
> Does anyone can tell me how to correct this error/what to look for.


Relevant Pages

  • Problems simulation plb_gemac core for Virtex-II Pro
    ... I'm trying to simulate a design generated with EDK 7.1 that uses the ... nav, and using a testbench added to the proj nav project), the loading ... binding for component at 'u0'. ... # (Port 'mgmntenbl' is not on the entity.) ...
    (comp.arch.fpga)
  • Deployment Error. Object reference not set to an instance of an ob
    ... Reading binding information for assembly ... "Graham.Corp.Ecom.Enterprise.Common.orchIDocInternalError" port ... Orchestration port is bound to send port ... assemblies. ...
    (microsoft.public.biztalk.general)
  • Re: Deployment Problem
    ... all Send/Receive port shapes are renamed. ... bindings that are set to point to a trusted host instance when the ... trusted/not trusted and needs to be the opposite. ... Failed to update binding information. ...
    (microsoft.public.biztalk.general)
  • RE: FTP
    ... If you're trying to specify the binding ... port to a receive shape, using the orchestration, in order to send the ... created in BizTalk Explorer to a shape in an orchestration. ...
    (microsoft.public.biztalk.server)
  • Re: tired of counting.... UDP socket bug
    ... UDP/53 is a DNS port. ... Try binding to a different port and see if it works. ... changing the socket type to UDP and binding ...
    (microsoft.public.dotnet.framework.aspnet.security)