[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [GSoC 2017] Support for fsysopts and multiple interfaces
From: |
Joan Lledó |
Subject: |
Re: [GSoC 2017] Support for fsysopts and multiple interfaces |
Date: |
Tue, 27 Jun 2017 19:09:08 +0200 |
2017-06-27 13:53 GMT+02:00 Joan Lledó <joanlluislledo@gmail.com>:
> Hi!
>
> 2017-06-27 1:19 GMT+02:00 Samuel Thibault <samuel.thibault@gnu.org>:
>> Hello,
>>
>> Joan Lledó, on lun. 26 juin 2017 13:28:47 +0200, wrote:
>>> As a curious factor, it's worth mentioning that pfinet had
>>> a memory leak that I could manage to fix.
>>
>> Could you provide a patch so we can benefit from it already? :)
>
> The leak is in [1]. When calling fsysopts, h is null and the previous
> h is lost. I could fix it by storing h as a global variable and
> freeing it in [1] if it's not null. Is that OK for you?
>
I've ben taking a look at it. There's no leak b/c there's no break in
the SUCCESS case, so it falls to the ERROR case and frees the hook.
Nothing to be done then. :)
>>
>>> Once the configuration from the command line is added, I checked that
>>> the translator now admits working with multiple interfaces
>>> simultaneously and routing between them. The limitation of having only
>>> one gateway has been left behind, but in return now a criteria to
>>> decide which gateway is the default one is needed. I haven't talked to
>>> the Hurd's developers about this, but for the moment, the first valid
>>> gateway provided by the user is set as the default one.
>>
>> That should be good enough for most purposes for now. Having several
>> gateways for 0.0.0.0/0 is really not a common thing :)
>>
>>> It's interesting to note that the example code[2] LwIP maintainers
>>> provide is wrong as well.
>>
>> It'll probably be useful to them to at least report the issue or even a
>> fix :)
>
> I know, and this is not the first issue I find, but I wouldn't like to
> just report it, I'd like to send them a patch too. I'll do it after my
> GSoC.
>
>>
>> Thanks!
>> Samuel
>
> ----------------
> [1] https://git.sceen.net/hurd/hurd.git/tree/pfinet/options.c#n387