| From: D. Hugh Redelmeier <[email protected]>

| I think that the type of marg in complete_v1_state_transition is such
| an error:
| 
|       time_t marg = deltamillisecs(
|               c->sa_rekey_margin);

This probably caused the addition of the cast in:

        if (delay_ms > (unsigned long)(marg * 1000)) {

I hope that it can be removed.

The multiplication was added too.  I think that it is wrong: both
delay_ms and marg are in units of a millisecond.  I hope that the
typing that I have advocated would have caught this.

(I only discovered the calculation error because I was trying to
describe the type error.  It is way more reliable to have the type
system do this checking.)
_______________________________________________
Swan-dev mailing list
[email protected]
https://lists.libreswan.org/mailman/listinfo/swan-dev

Reply via email to