I admit to not following the thread carefully; I find it difficult to follow prewritten cade (even my own) and maybe this has already been suggested, but wouldn't it work to:

Monitor two pins for input signal. First indication set TIMER to 0 and FLAG = 1.
Continue to monitor both pins
If "Other" pin indicates, capture TIMER as "elapsed count" variable, reset FLAG, and calculate for average (as the timer starts from 0 on each initial indication, there is no need to worry for rollover or complicated math).
If "Same" pin indicates, reset TIMER and FLAG = 1 (missed second signal indication - count errors if you like).

?