tlf-devel
[Top][All Lists]
Advanced

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

Re: [Tlf-devel] change ip addres tlf binds to?


From: Hegedüs Ervin
Subject: Re: [Tlf-devel] change ip addres tlf binds to?
Date: Wed, 26 Sep 2018 19:04:29 +0200
User-agent: Mutt/1.5.24 (2015-08-30)

Hi Eric,


On Wed, Sep 26, 2018 at 12:16:57PM -0400, Eric Tamme wrote:
> Hi Tom,
> 
> I guess my confusion lies in the fact that, there is no way to
> specify the bind ip for the socket server to listen on.

you're right.

Tlf (and nothing more) can't run more services on same ip:port.

You can check the source:

src/lancode.c:

   106  int lanrecv_init(void) {
   107      if (lan_active == 0)
   108          return (1);
   109  
   110      bzero(&lan_sin, sizeof(lan_sin));
   111      lan_sin.sin_family = AF_INET;
   112      lan_sin.sin_addr.s_addr = htonl(INADDR_ANY);
   113      lan_sin.sin_port = htons(resolveService(default_lan_service));
   114      lan_sin_len = sizeof(lan_sin);

only one receiver exists in one Tlf instance, and the receiver
socket is unconfigurable, as you can see. The address will be
0.0.0.0 (INADDR_ANY), port will be the default_lan_service (which
declared above of this part of code:

    66  /* default port to listen for incomming packets and to send packet to */
    67  char default_lan_service[16] = "6788";


so, I'm afraid you can't use more Tlf instances on same node
_if_you_want_ to connect the nodes. I think there isn't other
restriction.


73, Ervin





reply via email to

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