Bugfix: none proj must flap, undo previous commits, which may cause mess later

This commit is contained in:
Scott Lystig Fritchie 2015-08-29 13:13:23 +09:00
parent af0ade9840
commit f21fcdd7be

View file

@ -2294,10 +2294,9 @@ calculate_flaps(P_newprop, P_latest, _P_current, CurrentUp, _FlapLimit,
{_N, _} -> {_N, _} ->
?REACT({calculate_flaps,?LINE,[]}), ?REACT({calculate_flaps,?LINE,[]}),
false false
end end,
andalso %% TODO: 2015-08-29: Grr, we really need CP cases of none projection
%% If P_newprop is the none projection, do not start flapping. %% flapping to propagate problem_with information.
P_newprop#projection_v1.upi /= [],
LeaveFlapping_p = LeaveFlapping_p =
if if
LastUpChange_diff < 3.0 -> LastUpChange_diff < 3.0 ->
@ -2311,10 +2310,13 @@ calculate_flaps(P_newprop, P_latest, _P_current, CurrentUp, _FlapLimit,
%% that intent. %% that intent.
?REACT({calculate_flaps,?LINE,[]}), ?REACT({calculate_flaps,?LINE,[]}),
false; false;
AmFlappingNow_p andalso %% TODO: 2015-08-29: Grr, we really need CP cases of none projection
P_newprop#projection_v1.upi == [] -> %% flapping to propagate problem_with information.
%% P_newprop is the none projection, stop flapping. %% AmFlappingNow_p andalso
true; %% P_newprop#projection_v1.upi == [] ->
%% %% P_newprop is the none projection, stop flapping.
%% ?REACT({calculate_flaps,?LINE,[]}),
%% true;
AmFlappingNow_p andalso AmFlappingNow_p andalso
CurrentUp /= FlapLastUp -> CurrentUp /= FlapLastUp ->
?REACT({calculate_flaps,?LINE,[{manifesto_clause,{leave,1}}]}), ?REACT({calculate_flaps,?LINE,[{manifesto_clause,{leave,1}}]}),