On Thu, Aug 11, 2011 at 4:22 PM, Diego Biurrun <email address hidden> wrote: > review needs-fixing > > On Thu, Aug 11, 2011 at 01:46:52PM +0000, David Martin wrote: >> >> --- modules/update/hipd/update.c 2011-07-18 16:41:13 +0000 >> +++ modules/update/hipd/update.c 2011-08-11 13:46:45 +0000 >> @@ -157,6 +158,46 @@
> Geez, this is complicated.
I know I know, but there does not seem to be much you can do about it.
> Luckily some of it is redundant, witness: > > if (state->update_id_out_lower_bound <= hip_update_get_out_id(state)) { > if (ack_peer_update_id >= state->update_id_out_lower_bound && > ack_peer_update_id <= hip_update_get_out_id(state)) { > state->update_id_out_lower_bound = ack_peer_update_id; > return true; > } else { > if (ack_peer_update_id >= state->update_id_out_lower_bound || > ack_peer_update_id <= hip_update_get_out_id(state)) { > state->update_id_out_lower_bound = ack_peer_update_id; > return true; > } > return false;
Hah, you are awesome! Fixed it.
« Back to merge proposal
On Thu, Aug 11, 2011 at 4:22 PM, Diego Biurrun <email address hidden> wrote: update/ hipd/update. c 2011-07-18 16:41:13 +0000 update/ hipd/update. c 2011-08-11 13:46:45 +0000
> review needs-fixing
>
> On Thu, Aug 11, 2011 at 01:46:52PM +0000, David Martin wrote:
>>
>> --- modules/
>> +++ modules/
>> @@ -157,6 +158,46 @@
> Geez, this is complicated.
I know I know, but there does not seem to be much you can do about it.
> Luckily some of it is redundant, witness: >update_ id_out_ lower_bound <= hip_update_ get_out_ id(state) ) { update_ id_out_ lower_bound && get_out_ id(state) ) { update_ id_out_ lower_bound = ack_peer_update_id; update_ id_out_ lower_bound || get_out_ id(state) ) { update_ id_out_ lower_bound = ack_peer_update_id;
>
> if (state-
> if (ack_peer_update_id >= state->
> ack_peer_update_id <= hip_update_
> state->
> return true;
> } else {
> if (ack_peer_update_id >= state->
> ack_peer_update_id <= hip_update_
> state->
> return true;
> }
> return false;
Hah, you are awesome! Fixed it.