partysip-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Partysip-dev] REGARDING SO_REUSEADDR?


From: niv maman
Subject: [Partysip-dev] REGARDING SO_REUSEADDR?
Date: Tue, 20 Jan 2004 00:50:49 +0200

Hi.
First, let me say that your comments helped us a lot, and we almost finished
the compilation phase.
Just a reminder we are porting PartySip/OSip to Precise MQX/RTCS RTOS
(embedded Real time operating system on Motorola 68360)
This takes time because we are doing our best living PartySip project source
code as clean as possible.

Now trying to compile udp.c

I notice the use of setsockopt(..SO_REUSEADDR..) 3 times.
Our problem is that Precise MQX/RTCS do not support SO_REUSEADDR in
setsockopt(...)

Our project is not using multicast nor ipv6 so that lives me with two lines
of code where SO_REUSEADDR is used 

1.
int
local_ctx_init (int in_port, int out_port) 
{
.....
option = 1;
  i = setsockopt (ctx->in_socket, SOL_SOCKET, SO_REUSEADDR,
                  OPTVALCAST &option, sizeof option);
  if (i!=0)
    {
      OSIP_TRACE (osip_trace
                  (__FILE__, __LINE__, OSIP_WARNING, NULL,
                   "upd plugin; UDP listener SO_REUSE_ADDR failed %i
(%i)!\n",
                   ctx->in_port, i));
    }
....
}

2.
Inside udp_plugin_get_new_socke() where it is being called only by code
fragment enclosed by #ifdef SUPPORT_ICMP which is AFAIK not defined.


Can you please comment on those issues or give me an alternative for using
SO_REUSEADDR.

Really Really Thanks in advance.

Niv The Tool.








reply via email to

[Prev in Thread] Current Thread [Next in Thread]